10 RCSIDH(sha1_h,
"$Id: f096d1077fff60350abe74624bb45b8e3dc6052d $")
16 #include <freeradius-devel/build.h>
17 #include <freeradius-devel/missing.h>
19 #ifdef WITH_OPENSSL_SHA1
20 # include <freeradius-devel/tls/openssl_user_macros.h>
21 # include <openssl/sha.h>
28 #ifndef SHA1_DIGEST_LENGTH
29 # define SHA1_DIGEST_LENGTH 20
32 #ifndef WITH_OPENSSL_SHA1
52 # define fr_sha1_ctx SHA_CTX
53 # define fr_sha1_init SHA1_Init
54 # define fr_sha1_update SHA1_Update
55 # define fr_sha1_final SHA1_Final
56 # define fr_sha1_transform SHA1_Transform
62 uint8_t const *key,
size_t key_len);
static int const char char buffer[256]
#define USES_APPLE_DEPRECATED_API
#define SHA1_DIGEST_LENGTH
void fr_sha1_init(fr_sha1_ctx *context)
int fr_hmac_sha1(uint8_t digest[static SHA1_DIGEST_LENGTH], uint8_t const *in, size_t inlen, uint8_t const *key, size_t key_len)
Calculate HMAC using internal SHA1 implementation.
void fr_sha1_final_no_len(uint8_t digest[static SHA1_DIGEST_LENGTH], fr_sha1_ctx *context)
void fr_sha1_final(uint8_t digest[static SHA1_DIGEST_LENGTH], fr_sha1_ctx *context)
void fr_sha1_update(fr_sha1_ctx *context, uint8_t const *in, size_t len)
void fr_sha1_transform(uint32_t state[static 5], uint8_t const buffer[static 64])
static size_t char fr_sbuff_t size_t inlen