1 #if defined(WITH_SSL) || defined(WITH_LIBCRYPTO)
2 # include <openssl/sha.h>
4 /* public api for steve reid's public domain SHA-1 implementation */
5 /* this file is in the public domain */
10 #include <sys/types.h>
20 #define SHA_DIGEST_LENGTH 20
22 void SHA1_Transform(uint32_t state
[5], const uint8_t buffer
[64]);
24 void SHA1_Init(SHA_CTX
*context
);
25 void SHA1_Update(SHA_CTX
*context
, const uint8_t *data
, const size_t len
);
26 void SHA1_Final(uint8_t digest
[SHA_DIGEST_LENGTH
], SHA_CTX
*context
);