Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

20240622-SHA3-CRYPTO_CB #7675

Merged
merged 1 commit into from
Jun 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions wolfcrypt/src/cryptocb.c
Original file line number Diff line number Diff line change
Expand Up @@ -1606,7 +1606,7 @@ int wc_CryptoCb_Sha512Hash(wc_Sha512* sha512, const byte* in,
}
#endif /* WOLFSSL_SHA512 */

#ifdef WOLFSSL_SHA3
#if defined(WOLFSSL_SHA3) && (!defined(HAVE_FIPS) || FIPS_VERSION_GE(6, 0))
int wc_CryptoCb_Sha3Hash(wc_Sha3* sha3, int type, const byte* in,
word32 inSz, byte* digest)
{
Expand Down Expand Up @@ -1638,7 +1638,7 @@ int wc_CryptoCb_Sha3Hash(wc_Sha3* sha3, int type, const byte* in,

return wc_CryptoCb_TranslateErrorCode(ret);
}
#endif /* WOLFSSL_SHA3 */
#endif /* WOLFSSL_SHA3 && (!HAVE_FIPS || FIPS_VERSION_GE(6, 0)) */

#ifndef NO_HMAC
int wc_CryptoCb_Hmac(Hmac* hmac, int macType, const byte* in, word32 inSz,
Expand Down
2 changes: 1 addition & 1 deletion wolfcrypt/test/test.c
Original file line number Diff line number Diff line change
Expand Up @@ -54802,7 +54802,7 @@ static int myCryptoDevCb(int devIdArg, wc_CryptoInfo* info, void* ctx)
}
else
#endif
#ifdef WOLFSSL_SHA3
#if defined(WOLFSSL_SHA3) && (!defined(HAVE_FIPS) || FIPS_VERSION_GE(6, 0))
if (info->hash.type == WC_HASH_TYPE_SHA3_224) {
if (info->hash.sha3 == NULL)
return NOT_COMPILED_IN;
Expand Down