Search Linux Wireless

[PATCH] d80211: fix authentication issues

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



d80211: fix authentication issues

This patch prevents the MLME in d80211 from getting stuck when there is no
reply to authentication frames. It also allows the bssid to be correctly
set during IEEE80211_AUTHENTICATE.

Signed-off-by: Michael Wu <flamingice@xxxxxxxxxxxx>
---

 net/d80211/ieee80211_sta.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/net/d80211/ieee80211_sta.c b/net/d80211/ieee80211_sta.c
index feba62b..64dbc79 100644
--- a/net/d80211/ieee80211_sta.c
+++ b/net/d80211/ieee80211_sta.c
@@ -453,6 +453,7 @@ static void ieee80211_authenticate(struc
 		printk(KERN_DEBUG "%s: authentication with AP " MAC_FMT
 		       " timed out\n",
 		       dev->name, MAC_ARG(ifsta->bssid));
+		ifsta->state = IEEE80211_DISABLED;
 		return;
 	}
 
@@ -668,6 +669,7 @@ static void ieee80211_associate(struct n
 		printk(KERN_DEBUG "%s: association with AP " MAC_FMT
 		       " timed out\n",
 		       dev->name, MAC_ARG(ifsta->bssid));
+		ifsta->state = IEEE80211_DISABLED;
 		return;
 	}
 
@@ -677,6 +679,7 @@ static void ieee80211_associate(struct n
 	if (ieee80211_privacy_mismatch(dev, ifsta)) {
 		printk(KERN_DEBUG "%s: mismatch in privacy configuration and "
 		       "mixed-cell disabled - abort association\n", dev->name);
+		ifsta->state = IEEE80211_DISABLED;
 		return;
 	}
 
@@ -2355,7 +2358,7 @@ int ieee80211_sta_set_bssid(struct net_d
 		ifsta->bssid_set = 0;
 	else
 		ifsta->bssid_set = 1;
-	if (ifsta->ssid_set && ifsta->state != IEEE80211_AUTHENTICATE)
+	if (ifsta->ssid_set)
 		ieee80211_sta_new_auth(dev, ifsta);
 
 	return 0;

Attachment: pgpTjU8r3TdFK.pgp
Description: PGP signature


[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux