From c7053e9a361c929aed6c18b3c79e45a91a7dd437 Mon Sep 17 00:00:00 2001 From: David Garske Date: Thu, 12 Nov 2020 09:21:39 -0800 Subject: [PATCH] Fix scenario where `FreeHandshakeResources` is called and server hello is recevied and WOLFSSL arrays is NULL. --- src/sniffer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sniffer.c b/src/sniffer.c index bec413fa3..b1c8aab14 100644 --- a/src/sniffer.c +++ b/src/sniffer.c @@ -2648,7 +2648,7 @@ static int ProcessServerHello(int msgSz, const byte* input, int* sslBytes, (void)initialBytes; /* make sure we didn't miss ClientHello */ - if (session->flags.clientHello == 0) { + if (session->flags.clientHello == 0 || session->sslClient->arrays == NULL) { SetError(MISSED_CLIENT_HELLO_STR, error, session, FATAL_ERROR_STATE); return -1; }