]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
FT: Fix SAE + FT-SAE behavior in association parameter selection
authorJouni Malinen <jouni@codeaurora.org>
Tue, 26 Mar 2019 04:29:34 +0000 (06:29 +0200)
committerJouni Malinen <jouni@codeaurora.org>
Tue, 26 Mar 2019 20:50:17 +0000 (22:50 +0200)
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 <jouni@codeaurora.org>
wpa_supplicant/sme.c

index c435bf30557e1117ea20ac44654910c959c4d603..902c3e78fdcf80841ae966c7b337cb1ce820b875 100644 (file)
@@ -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]);