]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
FT: Fix hostapd with driver-based SME to authorize the STA
authorDarshan Paranji Sri <dparanji@qti.qualcomm.com>
Fri, 12 Sep 2014 15:46:56 +0000 (18:46 +0300)
committerJouni Malinen <j@w1.fi>
Fri, 12 Sep 2014 15:46:56 +0000 (18:46 +0300)
The driver-based SME case did not set STA flags properly to the kernel
in the way that hostapd-SME did in ieee802_11.c. This resulted in the FT
protocol case not marking the STA entry authorized. Fix that by handling
the special WLAN_AUTH_FT case in hostapd_notif_assoc() and also add the
forgotten hostapd_set_sta_flags() call to synchronize these flag to the
driver.

Signed-off-by: Jouni Malinen <jouni@qca.qualcomm.com>
src/ap/drv_callbacks.c

index ae4c968caad5c0ad908c87a85d2fc807c646d754..3bde7205db08c6583136248651a9baf0f5713cdd 100644 (file)
@@ -340,6 +340,9 @@ skip_wpa_check:
                                        sta->auth_alg, req_ies, req_ies_len);
 
        hostapd_sta_assoc(hapd, addr, reassoc, status, buf, p - buf);
+
+       if (sta->auth_alg == WLAN_AUTH_FT)
+               ap_sta_set_authorized(hapd, sta, 1);
 #else /* CONFIG_IEEE80211R */
        /* Keep compiler silent about unused variables */
        if (status) {
@@ -350,6 +353,8 @@ skip_wpa_check:
        sta->flags |= WLAN_STA_AUTH | WLAN_STA_ASSOC;
        sta->flags &= ~WLAN_STA_WNM_SLEEP_MODE;
 
+       hostapd_set_sta_flags(hapd, sta);
+
        if (reassoc && (sta->auth_alg == WLAN_AUTH_FT))
                wpa_auth_sm_event(sta->wpa_sm, WPA_ASSOC_FT);
        else