aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant
diff options
context:
space:
mode:
authorJouni Malinen <jouni@qca.qualcomm.com>2017-11-03 14:43:58 (GMT)
committerJouni Malinen <j@w1.fi>2017-11-03 17:59:46 (GMT)
commite0247e7983cdbd3bef6a6a15ed4450ccabde29ef (patch)
tree4df9d647c5432dc0e095c27527dde8bc28efb0a5 /wpa_supplicant
parent2265353a4fc57d66729a6c34b366ddc2bc6a3e16 (diff)
downloadhostap-e0247e7983cdbd3bef6a6a15ed4450ccabde29ef.zip
hostap-e0247e7983cdbd3bef6a6a15ed4450ccabde29ef.tar.gz
hostap-e0247e7983cdbd3bef6a6a15ed4450ccabde29ef.tar.bz2
DPP: PKEX and STATUS_BAD_GROUP
Report mismatching finite cyclic group with PKEX Exchange Response using STATUS_BAD_GROUP and provide more detailed error report over the control interface on the peer device when this happens. Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
Diffstat (limited to 'wpa_supplicant')
-rw-r--r--wpa_supplicant/dpp_supplicant.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/wpa_supplicant/dpp_supplicant.c b/wpa_supplicant/dpp_supplicant.c
index a53f7ab..9186a15 100644
--- a/wpa_supplicant/dpp_supplicant.c
+++ b/wpa_supplicant/dpp_supplicant.c
@@ -1427,6 +1427,19 @@ wpas_dpp_tx_pkex_status(struct wpa_supplicant *wpa_s,
wpa_msg(wpa_s, MSG_INFO, DPP_EVENT_TX_STATUS "dst=" MACSTR
" freq=%u result=%s", MAC2STR(dst), freq, res_txt);
/* TODO: Time out wait for response more quickly in error cases? */
+
+ if (!wpa_s->dpp_pkex) {
+ wpa_printf(MSG_DEBUG,
+ "DPP: Ignore TX status since there is no ongoing PKEX exchange");
+ return;
+ }
+
+ if (wpa_s->dpp_pkex->failed) {
+ wpa_printf(MSG_DEBUG,
+ "DPP: Terminate PKEX exchange due to an earlier error");
+ dpp_pkex_free(wpa_s->dpp_pkex);
+ wpa_s->dpp_pkex = NULL;
+ }
}