From: Jouni Malinen Date: Tue, 26 Mar 2019 04:29:34 +0000 (+0200) Subject: FT: Fix SAE + FT-SAE behavior in association parameter selection X-Git-Tag: hostap_2_8~164 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=322d328e71a4c6874d10ec169d18ea76e4a23bbe;p=thirdparty%2Fhostap.git FT: Fix SAE + FT-SAE behavior in association parameter selection Do not try to initialize FT reassociation if the selected AKM is for SAE instead of FT-SAE when both of these are enabled in a network profile. This fixes an issue with MDE being included in an (Re)Association Request frame even when using a non-FT AKM (which is something that results in hostapd rejecting the association). Signed-off-by: Jouni Malinen --- diff --git a/wpa_supplicant/sme.c b/wpa_supplicant/sme.c index c435bf305..902c3e78f 100644 --- a/wpa_supplicant/sme.c +++ b/wpa_supplicant/sme.c @@ -452,13 +452,14 @@ static void sme_send_authentication(struct wpa_supplicant *wpa_s, if (ie && ie[1] >= MOBILITY_DOMAIN_ID_LEN) md = ie + 2; wpa_sm_set_ft_params(wpa_s->wpa, ie, ie ? 2 + ie[1] : 0); + if (md && (!wpa_key_mgmt_ft(ssid->key_mgmt) || + !wpa_key_mgmt_ft(wpa_s->key_mgmt))) + md = NULL; if (md) { /* Prepare for the next transition */ wpa_ft_prepare_auth_request(wpa_s->wpa, ie); } - if (md && !wpa_key_mgmt_ft(ssid->key_mgmt)) - md = NULL; if (md) { wpa_dbg(wpa_s, MSG_DEBUG, "SME: FT mobility domain %02x%02x", md[0], md[1]);