Clear various flags on re-association to allow key_mgmt changes
[libeap.git] / hostapd / hostapd.c
index 6efe13f..225ad3a 100644 (file)
@@ -254,7 +254,8 @@ void hostapd_new_assoc_sta(struct hostapd_data *hapd, struct sta_info *sta,
        /* Start IEEE 802.1X authentication process for new stations */
        ieee802_1x_new_station(hapd, sta);
        if (reassoc) {
-               if (sta->auth_alg != WLAN_AUTH_FT)
+               if (sta->auth_alg != WLAN_AUTH_FT &&
+                   !(sta->flags & (WLAN_STA_WPS | WLAN_STA_MAYBE_WPS)))
                        wpa_auth_sm_event(sta->wpa_sm, WPA_REAUTH);
        } else
                wpa_auth_sta_associated(hapd->wpa_auth, sta->wpa_sm);