aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2003-06-09 02:47:02 (GMT)
committerJouni Malinen <j@w1.fi>2003-06-09 02:47:02 (GMT)
commit996d0048264917bac7696158a6754af3b5fff035 (patch)
treede514719c4279be0e6129322a6b90c01ad7372a2
parent86b4d7d15dc594312b5ed7cc39c303dbbe5dc934 (diff)
downloadhostap-history-996d0048264917bac7696158a6754af3b5fff035.zip
hostap-history-996d0048264917bac7696158a6754af3b5fff035.tar.gz
hostap-history-996d0048264917bac7696158a6754af3b5fff035.tar.bz2
Changed IEEE 802.11 authentication to mark STA authenticated when sending
authentication success message and not only after receiving ACK for this frame. IEEE 802.11 standard does not clearly state whether authentication state is changed on ACK or Auth sending. Setting it without waiting for ACK should not cause any problems and is not a security issue. Old behavior can be configured by defining IEEE80211_REQUIRE_AUTH_ACK.
-rw-r--r--hostapd/ieee802_11.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/hostapd/ieee802_11.c b/hostapd/ieee802_11.c
index 6b8c2ba..4374288 100644
--- a/hostapd/ieee802_11.c
+++ b/hostapd/ieee802_11.c
@@ -334,8 +334,12 @@ static u16 auth_shared_key(hostapd *hapd, struct sta_info *sta,
hostapd_logger(hapd, sta->addr, HOSTAPD_MODULE_IEEE80211,
HOSTAPD_LEVEL_DEBUG,
"authentication OK (shared key)");
+#ifdef IEEE80211_REQUIRE_AUTH_ACK
/* Station will be marked authenticated if it ACKs the
* authentication reply. */
+#else
+ sta->flags |= WLAN_STA_AUTH;
+#endif
free(sta->challenge);
sta->challenge = NULL;
@@ -487,8 +491,12 @@ static void handle_auth(hostapd *hapd, struct ieee80211_mgmt *mgmt, size_t len)
hostapd_logger(hapd, sta->addr, HOSTAPD_MODULE_IEEE80211,
HOSTAPD_LEVEL_DEBUG,
"authentication OK (open system)");
+#ifdef IEEE80211_REQUIRE_AUTH_ACK
/* Station will be marked authenticated if it ACKs the
* authentication reply. */
+#else
+ sta->flags |= WLAN_STA_AUTH;
+#endif
break;
case WLAN_AUTH_SHARED_KEY:
resp = auth_shared_key(hapd, sta, auth_transaction, challenge,