forked from wolfSSL/wolfssl
TI hash option control in hash.c
This commit is contained in:
@ -25,19 +25,21 @@
|
||||
|
||||
#include <wolfssl/wolfcrypt/settings.h>
|
||||
|
||||
#if !defined(NO_MD5) && !defined(WOLFSSL_TI_HASH)
|
||||
#if !defined(WOLFSSL_TI_HASH)
|
||||
|
||||
#if !defined(NO_MD5)
|
||||
#include <wolfssl/wolfcrypt/md5.h>
|
||||
#endif
|
||||
#if !defined(NO_SHA) && !defined(WOLFSSL_TI_HASH)
|
||||
#if !defined(NO_SHA)
|
||||
#include <wolfssl/wolfcrypt/sha.h>
|
||||
#endif
|
||||
#if !defined(NO_SHA256) && !defined(WOLFSSL_TI_HASH)
|
||||
#if !defined(NO_SHA256)
|
||||
#include <wolfssl/wolfcrypt/sha256.h>
|
||||
#endif
|
||||
|
||||
#include <wolfssl/wolfcrypt/hash.h>
|
||||
|
||||
#if !defined(NO_MD5) && !defined(WOLFSSL_TI_HASH)
|
||||
#if !defined(NO_MD5)
|
||||
void wc_Md5GetHash(Md5* md5, byte* hash)
|
||||
{
|
||||
Md5 save = *md5 ;
|
||||
@ -46,7 +48,7 @@ void wc_Md5GetHash(Md5* md5, byte* hash)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !defined(NO_SHA) && !defined(WOLFSSL_TI_HASH)
|
||||
#if !defined(NO_SHA)
|
||||
int wc_ShaGetHash(Sha* sha, byte* hash)
|
||||
{
|
||||
int ret ;
|
||||
@ -57,7 +59,7 @@ int wc_ShaGetHash(Sha* sha, byte* hash)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if !defined(NO_SHA256) && !defined(WOLFSSL_TI_HASH)
|
||||
#if !defined(NO_SHA256)
|
||||
int wc_Sha256GetHash(Sha256* sha256, byte* hash)
|
||||
{
|
||||
int ret ;
|
||||
@ -67,3 +69,6 @@ int wc_Sha256GetHash(Sha256* sha256, byte* hash)
|
||||
return ret ;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user