RSN: Validate RSNXE match in EAPOL-Key msg 3/4 only when RSN is used
This is needed to avoid the corner case of local RSNXE aware station being configured to behave as WPA(v1)-only STA when the AP might not include RSNXE in EAPOL-Key msg 3/4. Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
5acc20e8f4
commit
dc19779592
1 changed files with 6 additions and 5 deletions
|
@ -1572,11 +1572,12 @@ static int wpa_supplicant_validate_ie(struct wpa_sm *sm,
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((sm->ap_rsnxe && !ie->rsnxe) ||
|
if (sm->proto == WPA_PROTO_RSN &&
|
||||||
(!sm->ap_rsnxe && ie->rsnxe) ||
|
((sm->ap_rsnxe && !ie->rsnxe) ||
|
||||||
(sm->ap_rsnxe && ie->rsnxe &&
|
(!sm->ap_rsnxe && ie->rsnxe) ||
|
||||||
(sm->ap_rsnxe_len != ie->rsnxe_len ||
|
(sm->ap_rsnxe && ie->rsnxe &&
|
||||||
os_memcmp(sm->ap_rsnxe, ie->rsnxe, sm->ap_rsnxe_len) != 0))) {
|
(sm->ap_rsnxe_len != ie->rsnxe_len ||
|
||||||
|
os_memcmp(sm->ap_rsnxe, ie->rsnxe, sm->ap_rsnxe_len) != 0)))) {
|
||||||
wpa_msg(sm->ctx->msg_ctx, MSG_INFO,
|
wpa_msg(sm->ctx->msg_ctx, MSG_INFO,
|
||||||
"WPA: RSNXE mismatch between Beacon/ProbeResp and EAPOL-Key msg 3/4");
|
"WPA: RSNXE mismatch between Beacon/ProbeResp and EAPOL-Key msg 3/4");
|
||||||
wpa_hexdump(MSG_INFO, "RSNXE in Beacon/ProbeResp",
|
wpa_hexdump(MSG_INFO, "RSNXE in Beacon/ProbeResp",
|
||||||
|
|
Loading…
Add table
Reference in a new issue