From a5e7a20c939fabb426fd4a85c28afc135f2623e9 Mon Sep 17 00:00:00 2001 From: Lealem Amedie Date: Wed, 22 Mar 2023 17:29:13 -0600 Subject: [PATCH 1/3] Fix for logic gating strerror_r() --- wolfcrypt/test/test.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wolfcrypt/test/test.c b/wolfcrypt/test/test.c index 6fd425534..5f80924e1 100644 --- a/wolfcrypt/test/test.c +++ b/wolfcrypt/test/test.c @@ -651,7 +651,8 @@ static void render_error_message(const char* msg, int es) * infelicitous... */ #if !defined(STRING_USER) && !defined(NO_ERROR_STRINGS) && \ - (defined(_GNU_SOURCE) || defined(__USE_GNU) || \ + (defined(__STDC_VERSION__) && (__STDC_VERSION__ > 199901L)) && \ + ((defined(__GLIBC__) && (__GLIBC__ >= 2)) || \ (defined(__USE_XOPEN2K) && \ defined(_POSIX_C_SOURCE) && \ (_POSIX_C_SOURCE >= 200112L))) From c83e899b7803fa9e270ccb63fc1973fdf64595c9 Mon Sep 17 00:00:00 2001 From: Lealem Amedie Date: Wed, 22 Mar 2023 17:29:53 -0600 Subject: [PATCH 2/3] Fix for overlong string warning --- wolfcrypt/src/siphash.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/wolfcrypt/src/siphash.c b/wolfcrypt/src/siphash.c index 30947ab21..63df8051e 100644 --- a/wolfcrypt/src/siphash.c +++ b/wolfcrypt/src/siphash.c @@ -744,6 +744,12 @@ int wc_SipHash(const unsigned char* key, const unsigned char* in, word32 inSz, "cmp %w[outSz], #8\n\t" "b.eq L_siphash_8_end\n\t" + : [in] "+r" (in), [inSz] "+r" (inSz) + : [key] "r" (key), [out] "r" (out) , [outSz] "r" (outSz) + : "memory", "x8", "x9", "x10", "x11", "x12", "x13"); + + __asm__ __volatile__ ( + "mov w13, #0xee\n\t" "eor x10, x10, x13\n\t" #if WOLFSSL_SIPHASH_DROUNDS == 2 From a31ca24bb0e690ef62eb2aab801d264c5bf12c6f Mon Sep 17 00:00:00 2001 From: Lealem Amedie Date: Wed, 22 Mar 2023 17:30:38 -0600 Subject: [PATCH 3/3] Fix for async build with enable all --- src/internal.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/internal.c b/src/internal.c index 8c4328e7c..4d1bcc3a2 100644 --- a/src/internal.c +++ b/src/internal.c @@ -16045,8 +16045,8 @@ void SendFatalAlertOnly(WOLFSSL *ssl, int error) case WANT_WRITE: case WANT_READ: case ZERO_RETURN: -#ifdef WOLFSSL_ASYNC - case WC_PENGIND_E: +#ifdef WOLFSSL_ASYNC_CRYPT + case WC_PENDING_E: #endif return; case BUFFER_ERROR: