The FreeRADIUS server $Id: 15bac2a4c627c01d1aa2047687b3418955ac7f00 $
|
MD5 HMAC not dependent on OpenSSL. More...
#include <freeradius-devel/util/atexit.h>
#include <freeradius-devel/util/md5.h>
#include <freeradius-devel/util/strerror.h>
Go to the source code of this file.
Functions | |
int | fr_hmac_md5 (uint8_t digest[MD5_DIGEST_LENGTH], uint8_t const *in, size_t inlen, uint8_t const *key, size_t key_len) |
Calculate HMAC using internal MD5 implementation. | |
MD5 HMAC not dependent on OpenSSL.
For the sake of illustration we provide the following sample code for the implementation of HMAC-MD5 as well as some corresponding test vectors (the code is based on MD5 code as described in [MD5]).
Definition in file hmac_md5.c.
int fr_hmac_md5 | ( | uint8_t | digest[MD5_DIGEST_LENGTH], |
uint8_t const * | in, | ||
size_t | inlen, | ||
uint8_t const * | key, | ||
size_t | key_len | ||
) |
Calculate HMAC using internal MD5 implementation.
digest | Caller digest to be filled in. |
in | Pointer to data stream. |
inlen | length of data stream. |
key | Pointer to authentication key. |
key_len | Length of authentication key. |
Definition at line 119 of file hmac_md5.c.