From 3432cfa53e9d2157aaf7cf971510593ed9b14557 Mon Sep 17 00:00:00 2001 From: Ravi kumar Veeramally Date: Mon, 23 Mar 2015 23:06:11 +0200 Subject: [PATCH] eapol: Return if eapol_find_sm returns NULL --- src/eapol.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/eapol.c b/src/eapol.c index e5e8e0d2..eeff5b83 100644 --- a/src/eapol.c +++ b/src/eapol.c @@ -785,6 +785,8 @@ void __eapol_rx_packet(uint32_t ifindex, const uint8_t *spa, const uint8_t *aa, return; sm = eapol_find_sm(ifindex, spa, aa); + if (!sm) + return; /* Wrong direction */ if (!ek->key_ack)