From 3223920fd95b637009ac259c2de1201cf6a048ef Mon Sep 17 00:00:00 2001 From: John Safranek Date: Wed, 13 Feb 2019 12:23:12 -0800 Subject: [PATCH] Add a guard for AES-GCM and AES-CCM for the change in Encrypt for the AES-AEAD type and macros. --- src/internal.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/internal.c b/src/internal.c index 3962aa117..bc65a2ff7 100644 --- a/src/internal.c +++ b/src/internal.c @@ -11830,6 +11830,8 @@ static int ChachaAEADDecrypt(WOLFSSL* ssl, byte* plain, const byte* input, #endif /* HAVE_AEAD */ +#if defined(BUILD_AESGCM) || defined(HAVE_AESCCM) + #if (!defined(HAVE_FIPS) && !defined(HAVE_SELFTEST)) || \ (defined(HAVE_FIPS_VERSION) && (HAVE_FIPS_VERSION >= 2)) /* The following type is used to share code between AES-GCM and AES-CCM. */ @@ -11847,6 +11849,8 @@ static int ChachaAEADDecrypt(WOLFSSL* ssl, byte* plain, const byte* input, #define AES_CCM_ENCRYPT wc_AesCcmEncrypt #endif +#endif + static WC_INLINE int EncryptDo(WOLFSSL* ssl, byte* out, const byte* input, word16 sz, int asyncOkay)