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>
This commit is contained in:
Jouni Malinen 2017-11-03 16:43:58 +02:00 committed by Jouni Malinen
parent 2265353a4f
commit e0247e7983
4 changed files with 73 additions and 16 deletions

View file

@ -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;
}
}