OWE: Avoid incorrect profile update in transition mode
The "unexpected" change of SSID between the current network profile
(which uses the SSID from the open BSS in OWE transition mode) and the
association with the OWE BSS (which uses a random, hidden SSID) resulted
in wpa_supplicant incorrectly determining that this was a
driver-initiated BSS selection ("Driver-initiated BSS selection changed
the SSID to <the random SSID from OWE BSS>" in debug log).
This ended up with updating security parameters based on the network
profile inwpa_supplicant_set_suites() instead of using the already
discovered information from scan results. In particular, this cleared
the RSN supplicant state machine information of AP RSNE and resulted in
having to fetch the scan results for the current BSS when processing
EAPOL-Key msg 3/4.
Fix this by recognizing the special case for OWE transition mode where
the SSID for the associated AP does not actually match the SSID in the
network profile.
Signed-off-by: Jouni Malinen <j@w1.fi>
This commit is contained in:
parent
785f99b680
commit
ecb5219d8c
2 changed files with 12 additions and 0 deletions
|
|
@ -18,6 +18,7 @@ struct wpa_scan_res;
|
|||
#define WPA_BSS_AUTHENTICATED BIT(4)
|
||||
#define WPA_BSS_ASSOCIATED BIT(5)
|
||||
#define WPA_BSS_ANQP_FETCH_TRIED BIT(6)
|
||||
#define WPA_BSS_OWE_TRANSITION BIT(7)
|
||||
|
||||
struct wpa_bss_anqp_elem {
|
||||
struct dl_list list;
|
||||
|
|
|
|||
|
|
@ -188,6 +188,16 @@ static int wpa_supplicant_select_config(struct wpa_supplicant *wpa_s)
|
|||
drv_ssid_len) == 0)
|
||||
return 0; /* current profile still in use */
|
||||
|
||||
#ifdef CONFIG_OWE
|
||||
if ((wpa_s->current_ssid->key_mgmt & WPA_KEY_MGMT_OWE) &&
|
||||
wpa_s->current_bss &&
|
||||
(wpa_s->current_bss->flags & WPA_BSS_OWE_TRANSITION) &&
|
||||
drv_ssid_len == wpa_s->current_bss->ssid_len &&
|
||||
os_memcmp(drv_ssid, wpa_s->current_bss->ssid,
|
||||
drv_ssid_len) == 0)
|
||||
return 0; /* current profile still in use */
|
||||
#endif /* CONFIG_OWE */
|
||||
|
||||
wpa_msg(wpa_s, MSG_DEBUG,
|
||||
"Driver-initiated BSS selection changed the SSID to %s",
|
||||
wpa_ssid_txt(drv_ssid, drv_ssid_len));
|
||||
|
|
@ -1025,6 +1035,7 @@ static void owe_trans_ssid(struct wpa_supplicant *wpa_s, struct wpa_bss *bss,
|
|||
wpa_ssid_txt(pos, ssid_len));
|
||||
os_memcpy(bss->ssid, pos, ssid_len);
|
||||
bss->ssid_len = ssid_len;
|
||||
bss->flags |= WPA_BSS_OWE_TRANSITION;
|
||||
#endif /* CONFIG_OWE */
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue