From 445ed2f234a19c3856c6a90e07aa5062cd07e6ce Mon Sep 17 00:00:00 2001 From: Juliusz Sosinowicz Date: Sat, 12 Feb 2022 00:34:24 +0100 Subject: [PATCH] Reported in ZD13631 `ssl->peerVerifyRet` wasn't being cleared when retrying with an alternative cert chain --- src/internal.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/internal.c b/src/internal.c index bdb0cee69..55072d8fe 100644 --- a/src/internal.c +++ b/src/internal.c @@ -12340,6 +12340,9 @@ int ProcessPeerCerts(WOLFSSL* ssl, byte* input, word32* inOutIdx, } ret = 0; /* clear errors and continue */ + #if defined(OPENSSL_EXTRA) || defined(OPENSSL_EXTRA_X509_SMALL) + ssl->peerVerifyRet = 0; + #endif args->verifyErr = 0; }