forked from wolfSSL/wolfssl
Fix to not allow Shake128/256 with Xilinx AFALG. Cleanup the Shake disable logic to allow forcing off with WOLFSSL_NO_SHAKE128
and WOLFSSL_NO_SHAKE256
.
This commit is contained in:
@ -2032,6 +2032,8 @@ extern void uITRON4_free(void *p) ;
|
||||
#define WOLFSSL_NOSHA3_224
|
||||
#define WOLFSSL_NOSHA3_256
|
||||
#define WOLFSSL_NOSHA3_512
|
||||
#define WOLFSSL_NO_SHAKE128
|
||||
#define WOLFSSL_NO_SHAKE256
|
||||
#endif
|
||||
#ifdef WOLFSSL_AFALG_XILINX_AES
|
||||
#undef WOLFSSL_AES_DIRECT
|
||||
@ -3475,22 +3477,27 @@ extern void uITRON4_free(void *p) ;
|
||||
#define WOLFSSL_RSA_KEY_CHECK
|
||||
#endif
|
||||
|
||||
/* ED448 Requires Shake256 */
|
||||
#if defined(HAVE_ED448) && defined(WOLFSSL_SHA3)
|
||||
#undef WOLFSSL_SHAKE256
|
||||
#define WOLFSSL_SHAKE256
|
||||
#endif
|
||||
|
||||
/* SHAKE - Not allowed in FIPS */
|
||||
#if defined(WOLFSSL_SHA3) && !defined(HAVE_SELFTEST) && !defined(HAVE_FIPS)
|
||||
#ifndef WOLFSSL_NO_SHAKE128
|
||||
#undef WOLFSSL_SHAKE128
|
||||
#define WOLFSSL_SHAKE128
|
||||
#endif
|
||||
#ifndef WOLFSSL_NO_SHAKE256
|
||||
#undef WOLFSSL_SHAKE256
|
||||
#define WOLFSSL_SHAKE256
|
||||
#endif
|
||||
#else
|
||||
#if defined(WOLFSSL_SHA3) && (defined(HAVE_SELFTEST) || defined(HAVE_FIPS))
|
||||
#undef WOLFSSL_NO_SHAKE128
|
||||
#define WOLFSSL_NO_SHAKE128
|
||||
#undef WOLFSSL_NO_SHAKE256
|
||||
#define WOLFSSL_NO_SHAKE256
|
||||
#endif
|
||||
/* SHAKE Disable */
|
||||
#ifdef WOLFSSL_NO_SHAKE128
|
||||
#undef WOLFSSL_SHAKE128
|
||||
#endif
|
||||
#ifdef WOLFSSL_NO_SHAKE256
|
||||
#undef WOLFSSL_SHAKE256
|
||||
#endif
|
||||
|
||||
|
||||
/* Encrypted Client Hello - requires HPKE */
|
||||
#if defined(HAVE_ECH) && !defined(HAVE_HPKE)
|
||||
|
Reference in New Issue
Block a user