aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant
diff options
context:
space:
mode:
authorJouni Malinen <jouni@qca.qualcomm.com>2017-11-03 15:13:17 (GMT)
committerJouni Malinen <j@w1.fi>2017-11-03 17:59:46 (GMT)
commit039b8e73699db28dea59c479d551b46adbc9d8f5 (patch)
tree7848fd2c99ee38bd4a04951431db2647ab8e06f2 /wpa_supplicant
parentfc0efa2a1ec6a4fbe36a3baaa7608b85b0fc3298 (diff)
downloadhostap-039b8e73699db28dea59c479d551b46adbc9d8f5.zip
hostap-039b8e73699db28dea59c479d551b46adbc9d8f5.tar.gz
hostap-039b8e73699db28dea59c479d551b46adbc9d8f5.tar.bz2
DPP: Terminate PKEX exchange on detection of a mismatching code
Clean up the pending PKEX exchange if Commit-Reveal Request processing indicates a mismatch in the PKEX code. Previously, the this case was silently ignored and the session was left in pending state that prevented new PKEX exchanges from getting initated. Now, a new attempt is allowed to be initiated. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'wpa_supplicant')
-rw-r--r--wpa_supplicant/dpp_supplicant.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/wpa_supplicant/dpp_supplicant.c b/wpa_supplicant/dpp_supplicant.c
index 9186a15..87131f5 100644
--- a/wpa_supplicant/dpp_supplicant.c
+++ b/wpa_supplicant/dpp_supplicant.c
@@ -1556,6 +1556,11 @@ wpas_dpp_rx_pkex_commit_reveal_req(struct wpa_supplicant *wpa_s, const u8 *src,
msg = dpp_pkex_rx_commit_reveal_req(pkex, hdr, buf, len);
if (!msg) {
wpa_printf(MSG_DEBUG, "DPP: Failed to process the request");
+ if (pkex->failed) {
+ wpa_printf(MSG_DEBUG, "DPP: Terminate PKEX exchange");
+ dpp_pkex_free(wpa_s->dpp_pkex);
+ wpa_s->dpp_pkex = NULL;
+ }
return;
}