From 757f3b81059d3ac44a7b55dc1f9a5dfc0bda92f7 Mon Sep 17 00:00:00 2001 From: Kareem Date: Thu, 18 Nov 2021 16:06:22 -0700 Subject: [PATCH] Fix building Import/ExportOptions with HAVE_ENCRYPT_THEN_MAC undefined. --- src/internal.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/internal.c b/src/internal.c index 3a02a84c4..c66dc02a8 100644 --- a/src/internal.c +++ b/src/internal.c @@ -1186,10 +1186,12 @@ static int ExportOptions(WOLFSSL* ssl, byte* exp, word32 len, byte ver, exp[idx++] = options->asyncState; if (type == WOLFSSL_EXPORT_TLS) { +#ifdef HAVE_ENCRYPT_THEN_MAC exp[idx++] = options->disallowEncThenMac; exp[idx++] = options->encThenMac; exp[idx++] = options->startedETMRead; exp[idx++] = options->startedETMWrite; +#endif } /* version of connection */ @@ -1362,10 +1364,12 @@ static int ImportOptions(WOLFSSL* ssl, const byte* exp, word32 len, byte ver, options->asyncState = exp[idx++]; if (type == WOLFSSL_EXPORT_TLS) { +#ifdef HAVE_ENCRYPT_THEN_MAC options->disallowEncThenMac = exp[idx++]; options->encThenMac = exp[idx++]; options->startedETMRead = exp[idx++]; options->startedETMWrite = exp[idx++]; +#endif } /* version of connection */