forked from wolfSSL/wolfssl
tls13.c: mac2hash(): accommodate scenario where all hashes are gated out of the build (peer review).
This commit is contained in:
@ -332,7 +332,7 @@ static int DeriveKey(WOLFSSL* ssl, byte* output, int outputLen,
|
|||||||
*/
|
*/
|
||||||
static WC_INLINE int mac2hash(int mac)
|
static WC_INLINE int mac2hash(int mac)
|
||||||
{
|
{
|
||||||
int hash = WC_HASH_TYPE_NONE;
|
int hash;
|
||||||
switch (mac) {
|
switch (mac) {
|
||||||
#ifndef NO_SHA256
|
#ifndef NO_SHA256
|
||||||
case sha256_mac:
|
case sha256_mac:
|
||||||
@ -351,6 +351,8 @@ static WC_INLINE int mac2hash(int mac)
|
|||||||
hash = WC_SHA512;
|
hash = WC_SHA512;
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
default:
|
||||||
|
hash = WC_HASH_TYPE_NONE;
|
||||||
}
|
}
|
||||||
return hash;
|
return hash;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user