Electroneum
Loading...
Searching...
No Matches
md5 Namespace Reference

Classes

struct  HMAC_MD5_CTX_s
struct  HMAC_MD5_STATE_s
struct  MD5_CTX

Typedefs

typedef struct md5::HMAC_MD5_CTX_s HMAC_MD5_CTX
typedef struct md5::HMAC_MD5_STATE_s HMAC_MD5_STATE
typedef unsigned char * POINTER
typedef unsigned short int UINT2
typedef unsigned int UINT4

Functions

void hmac_md5 (const unsigned char *text, int text_len, const unsigned char *key, int key_len, unsigned char digest[HMAC_MD5_SIZE])
void hmac_md5_init (HMAC_MD5_CTX *hmac, const unsigned char *key, int key_len)
void hmac_md5_precalc (HMAC_MD5_STATE *hmac, const unsigned char *key, int key_len)
void hmac_md5_import (HMAC_MD5_CTX *hmac, HMAC_MD5_STATE *state)
void hmac_md5_final (unsigned char digest[HMAC_MD5_SIZE], HMAC_MD5_CTX *hmac)
bool md5 (unsigned char *input, int ilen, unsigned char output[16])

Typedef Documentation

◆ HMAC_MD5_CTX

◆ HMAC_MD5_STATE

◆ POINTER

typedef unsigned char* md5::POINTER

Definition at line 56 of file md5global.h.

◆ UINT2

typedef unsigned short int md5::UINT2

Definition at line 59 of file md5global.h.

◆ UINT4

typedef unsigned int md5::UINT4

Definition at line 63 of file md5global.h.

Function Documentation

◆ hmac_md5()

void md5::hmac_md5 ( const unsigned char * text,
int text_len,
const unsigned char * key,
int key_len,
unsigned char digest[HMAC_MD5_SIZE] )

◆ hmac_md5_final()

void md5::hmac_md5_final ( unsigned char digest[HMAC_MD5_SIZE],
HMAC_MD5_CTX * hmac )

◆ hmac_md5_import()

void md5::hmac_md5_import ( HMAC_MD5_CTX * hmac,
HMAC_MD5_STATE * state )

◆ hmac_md5_init()

void md5::hmac_md5_init ( HMAC_MD5_CTX * hmac,
const unsigned char * key,
int key_len )

◆ hmac_md5_precalc()

void md5::hmac_md5_precalc ( HMAC_MD5_STATE * hmac,
const unsigned char * key,
int key_len )

◆ md5()

bool md5::md5 ( unsigned char * input,
int ilen,
unsigned char output[16] )
inline

Definition at line 80 of file md5_l.h.

81 {
82 MD5_CTX ctx;
83
84 MD5Init( &ctx );
85 MD5Update( &ctx, input, ilen );
86 MD5Final( output, &ctx);
87
88 memset( &ctx, 0, sizeof( MD5_CTX) );
89 return true;
90 }