forked from wolfSSL/wolfssl
Add SHA1 OpenSSL
This commit is contained in:
@@ -21,6 +21,11 @@ void SHA_Init(SHA_CTX*);
|
|||||||
void SHA_Update(SHA_CTX*, const void*, unsigned long);
|
void SHA_Update(SHA_CTX*, const void*, unsigned long);
|
||||||
void SHA_Final(unsigned char*, SHA_CTX*);
|
void SHA_Final(unsigned char*, SHA_CTX*);
|
||||||
|
|
||||||
|
/* SHA1 points to above, shouldn't use SHA0 ever */
|
||||||
|
void SHA1_Init(SHA_CTX*);
|
||||||
|
void SHA1_Update(SHA_CTX*, const void*, unsigned long);
|
||||||
|
void SHA1_Final(unsigned char*, SHA_CTX*);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
|
18
src/ssl.c
18
src/ssl.c
@@ -2453,6 +2453,24 @@ int CyaSSL_set_compression(SSL* ssl)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void SHA1_Init(SHA_CTX* sha)
|
||||||
|
{
|
||||||
|
SHA_Init(sha);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void SHA1_Update(SHA_CTX* sha, const void* input, unsigned long sz)
|
||||||
|
{
|
||||||
|
SHA_Update(sha, input, sz);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void SHA1_Final(byte* input, SHA_CTX* sha)
|
||||||
|
{
|
||||||
|
SHA_Final(input, sha);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
const EVP_MD* EVP_md5(void)
|
const EVP_MD* EVP_md5(void)
|
||||||
{
|
{
|
||||||
static const char* type = "MD5";
|
static const char* type = "MD5";
|
||||||
|
Reference in New Issue
Block a user