From 61545df606c95a045fedb64d7d9a21d3a31d3519 Mon Sep 17 00:00:00 2001 From: David Garske Date: Wed, 26 Aug 2020 09:41:26 -0700 Subject: [PATCH] Fix to make sure DTLS cookie HMAC free gets called. Note: This does not cover the many error case paths. --- src/internal.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/internal.c b/src/internal.c index dc57df024..8ded80642 100644 --- a/src/internal.c +++ b/src/internal.c @@ -27563,6 +27563,8 @@ static int DoSessionTicket(WOLFSSL* ssl, const byte* input, word32* inOutIdx, } #endif #ifdef WOLFSSL_DTLS + wc_HmacFree(&cookieHmac); + if (ret == 0 && ssl->options.dtls) DtlsMsgPoolReset(ssl); #endif