#include "setup.h"#include <string.h>#include "md5.h"Go to the source code of this file.
Classes | |
| struct | md5_ctx |
Defines | |
| #define | S11 7 |
| #define | S12 12 |
| #define | S13 17 |
| #define | S14 22 |
| #define | S21 5 |
| #define | S22 9 |
| #define | S23 14 |
| #define | S24 20 |
| #define | S31 4 |
| #define | S32 11 |
| #define | S33 16 |
| #define | S34 23 |
| #define | S41 6 |
| #define | S42 10 |
| #define | S43 15 |
| #define | S44 21 |
| #define | F(x, y, z) (((x) & (y)) | ((~x) & (z))) |
| #define | G(x, y, z) (((x) & (z)) | ((y) & (~z))) |
| #define | H(x, y, z) ((x) ^ (y) ^ (z)) |
| #define | I(x, y, z) ((y) ^ ((x) | (~z))) |
| #define | ROTATE_LEFT(x, n) (((x) << (n)) | ((x) >> (32-(n)))) |
| #define | FF(a, b, c, d, x, s, ac) |
| #define | GG(a, b, c, d, x, s, ac) |
| #define | HH(a, b, c, d, x, s, ac) |
| #define | II(a, b, c, d, x, s, ac) |
Typedefs | |
| typedef unsigned int | UINT4 |
| typedef struct md5_ctx | MD5_CTX |
Functions | |
| static void | MD5_Init (struct md5_ctx *) |
| static void | MD5_Update (struct md5_ctx *, const unsigned char *, unsigned int) |
| static void | MD5_Final (unsigned char[16], struct md5_ctx *) |
| static void | MD5Transform (UINT4[4], const unsigned char[64]) |
| static void | Encode (unsigned char *, UINT4 *, unsigned int) |
| static void | Decode (UINT4 *, const unsigned char *, unsigned int) |
| void | Curl_md5it (unsigned char *outbuffer, const unsigned char *input) |
Variables | |
| static const unsigned char | PADDING [64] |
| #define S11 7 |
| #define S12 12 |
| #define S13 17 |
| #define S14 22 |
| #define S21 5 |
| #define S22 9 |
| #define S23 14 |
| #define S24 20 |
| #define S31 4 |
| #define S32 11 |
| #define S33 16 |
| #define S34 23 |
| #define S41 6 |
| #define S42 10 |
| #define S43 15 |
| #define S44 21 |
| void Curl_md5it | ( | unsigned char * | outbuffer, | |
| const unsigned char * | input | |||
| ) |
Definition at line 343 of file md5.c.
References MD5_Final(), MD5_Init(), and MD5_Update().
Referenced by Curl_output_digest().
| static void Decode | ( | UINT4 * | output, | |
| const unsigned char * | input, | |||
| unsigned int | len | |||
| ) | [static] |
| static void Encode | ( | unsigned char * | output, | |
| UINT4 * | input, | |||
| unsigned int | len | |||
| ) | [static] |
| static void MD5_Final | ( | unsigned char | digest[16], | |
| struct md5_ctx * | context | |||
| ) | [static] |
Definition at line 191 of file md5.c.
References bits, md5_ctx::count, count, Encode(), MD5_Update(), PADDING, and md5_ctx::state.
Referenced by Curl_md5it().
| static void MD5_Init | ( | struct md5_ctx * | context | ) | [static] |
Definition at line 140 of file md5.c.
References md5_ctx::count, and md5_ctx::state.
Referenced by Curl_md5it().
| static void MD5_Update | ( | struct md5_ctx * | context, | |
| const unsigned char * | input, | |||
| unsigned int | inputLen | |||
| ) | [static] |
Definition at line 154 of file md5.c.
References md5_ctx::buffer, md5_ctx::count, MD5Transform(), and md5_ctx::state.
Referenced by Curl_md5it(), and MD5_Final().
| static void MD5Transform | ( | UINT4 | state[4], | |
| const unsigned char | block[64] | |||
| ) | [static] |
const unsigned char PADDING[64] [static] |
Initial value:
{
0x80, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
}
Definition at line 97 of file md5.c.
Referenced by MD5_Final().
1.5.6