From c6df620f817561ee4fbe4482b9e50d8da32fbab6 Mon Sep 17 00:00:00 2001 From: Daniel Pouzzner Date: Tue, 26 Nov 2024 13:09:39 -0600 Subject: [PATCH] wolfssl/wolfcrypt/aes.h: #define WC_NO_COMPAT_AES_BLOCK_SIZE in OPENSSL_COEXIST builds. see comment in source code with usage instructions. --- wolfssl/wolfcrypt/aes.h | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/wolfssl/wolfcrypt/aes.h b/wolfssl/wolfcrypt/aes.h index a5399017a..61a3433ea 100644 --- a/wolfssl/wolfcrypt/aes.h +++ b/wolfssl/wolfcrypt/aes.h @@ -189,7 +189,15 @@ enum { #endif WC_AES_BLOCK_SIZE = 16, -#ifndef OPENSSL_COEXIST +#ifdef OPENSSL_COEXIST + /* allow OPENSSL_COEXIST applications to detect absence of AES_BLOCK_SIZE + * and presence of WC_AES_BLOCK_SIZE. + * + * if WC_NO_COMPAT_AES_BLOCK_SIZE is defined, WC_AES_BLOCK_SIZE is + * available, otherwise AES_BLOCK_SIZE is available. + */ + #define WC_NO_COMPAT_AES_BLOCK_SIZE +#else #define AES_BLOCK_SIZE WC_AES_BLOCK_SIZE #endif