diff options
author | Jeff Garzik <jeff@garzik.org> | 2006-07-29 00:32:29 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-07-29 00:32:29 -0400 |
commit | 5b84b6fa9b96d1598eb77196f9d8b3e62efac647 (patch) | |
tree | c8bae5786c369e42ac7eba9191fbad0721bcd73c | |
parent | e3f2ddeac718c768fdac4b7fe69d465172f788a8 (diff) | |
parent | ca0084fa90533687b6317e6d084141da87c74d5c (diff) |
Merge branch 'upstream-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6 into upstream-fixes
-rw-r--r-- | drivers/net/wireless/Kconfig | 1 | ||||
-rw-r--r-- | drivers/net/wireless/bcm43xx/bcm43xx_main.c | 2 | ||||
-rw-r--r-- | drivers/net/wireless/orinoco.c | 4 | ||||
-rw-r--r-- | drivers/net/wireless/zd1201.c | 2 | ||||
-rw-r--r-- | net/ieee80211/Kconfig | 1 | ||||
-rw-r--r-- | net/ieee80211/softmac/ieee80211softmac_auth.c | 28 |
6 files changed, 29 insertions, 9 deletions
diff --git a/drivers/net/wireless/Kconfig b/drivers/net/wireless/Kconfig index fa9d2c4edc93..2e8ac995d56f 100644 --- a/drivers/net/wireless/Kconfig +++ b/drivers/net/wireless/Kconfig | |||
@@ -447,6 +447,7 @@ config AIRO_CS | |||
447 | tristate "Cisco/Aironet 34X/35X/4500/4800 PCMCIA cards" | 447 | tristate "Cisco/Aironet 34X/35X/4500/4800 PCMCIA cards" |
448 | depends on NET_RADIO && PCMCIA && (BROKEN || !M32R) | 448 | depends on NET_RADIO && PCMCIA && (BROKEN || !M32R) |
449 | select CRYPTO | 449 | select CRYPTO |
450 | select CRYPTO_AES | ||
450 | ---help--- | 451 | ---help--- |
451 | This is the standard Linux driver to support Cisco/Aironet PCMCIA | 452 | This is the standard Linux driver to support Cisco/Aironet PCMCIA |
452 | 802.11 wireless cards. This driver is the same as the Aironet | 453 | 802.11 wireless cards. This driver is the same as the Aironet |
diff --git a/drivers/net/wireless/bcm43xx/bcm43xx_main.c b/drivers/net/wireless/bcm43xx/bcm43xx_main.c index 3889f79e7128..df317c1e12a8 100644 --- a/drivers/net/wireless/bcm43xx/bcm43xx_main.c +++ b/drivers/net/wireless/bcm43xx/bcm43xx_main.c | |||
@@ -3701,7 +3701,7 @@ static void bcm43xx_ieee80211_set_security(struct net_device *net_dev, | |||
3701 | } | 3701 | } |
3702 | if (sec->flags & SEC_AUTH_MODE) { | 3702 | if (sec->flags & SEC_AUTH_MODE) { |
3703 | secinfo->auth_mode = sec->auth_mode; | 3703 | secinfo->auth_mode = sec->auth_mode; |
3704 | dprintk(", .auth_mode = %d\n", sec->auth_mode); | 3704 | dprintk(", .auth_mode = %d", sec->auth_mode); |
3705 | } | 3705 | } |
3706 | dprintk("\n"); | 3706 | dprintk("\n"); |
3707 | if (bcm43xx_status(bcm) == BCM43xx_STAT_INITIALIZED && | 3707 | if (bcm43xx_status(bcm) == BCM43xx_STAT_INITIALIZED && |
diff --git a/drivers/net/wireless/orinoco.c b/drivers/net/wireless/orinoco.c index d6ed5781b93a..317ace7f9aae 100644 --- a/drivers/net/wireless/orinoco.c +++ b/drivers/net/wireless/orinoco.c | |||
@@ -2875,7 +2875,7 @@ static int orinoco_ioctl_setiwencode(struct net_device *dev, | |||
2875 | if (orinoco_lock(priv, &flags) != 0) | 2875 | if (orinoco_lock(priv, &flags) != 0) |
2876 | return -EBUSY; | 2876 | return -EBUSY; |
2877 | 2877 | ||
2878 | if (erq->pointer) { | 2878 | if (erq->length > 0) { |
2879 | if ((index < 0) || (index >= ORINOCO_MAX_KEYS)) | 2879 | if ((index < 0) || (index >= ORINOCO_MAX_KEYS)) |
2880 | index = priv->tx_key; | 2880 | index = priv->tx_key; |
2881 | 2881 | ||
@@ -2918,7 +2918,7 @@ static int orinoco_ioctl_setiwencode(struct net_device *dev, | |||
2918 | if (erq->flags & IW_ENCODE_RESTRICTED) | 2918 | if (erq->flags & IW_ENCODE_RESTRICTED) |
2919 | restricted = 1; | 2919 | restricted = 1; |
2920 | 2920 | ||
2921 | if (erq->pointer) { | 2921 | if (erq->pointer && erq->length > 0) { |
2922 | priv->keys[index].len = cpu_to_le16(xlen); | 2922 | priv->keys[index].len = cpu_to_le16(xlen); |
2923 | memset(priv->keys[index].data, 0, | 2923 | memset(priv->keys[index].data, 0, |
2924 | sizeof(priv->keys[index].data)); | 2924 | sizeof(priv->keys[index].data)); |
diff --git a/drivers/net/wireless/zd1201.c b/drivers/net/wireless/zd1201.c index 662ecc8a33ff..c52e9bcf8d02 100644 --- a/drivers/net/wireless/zd1201.c +++ b/drivers/net/wireless/zd1201.c | |||
@@ -1820,6 +1820,8 @@ static int zd1201_probe(struct usb_interface *interface, | |||
1820 | zd->dev->name); | 1820 | zd->dev->name); |
1821 | 1821 | ||
1822 | usb_set_intfdata(interface, zd); | 1822 | usb_set_intfdata(interface, zd); |
1823 | zd1201_enable(zd); /* zd1201 likes to startup enabled, */ | ||
1824 | zd1201_disable(zd); /* interfering with all the wifis in range */ | ||
1823 | return 0; | 1825 | return 0; |
1824 | 1826 | ||
1825 | err_net: | 1827 | err_net: |
diff --git a/net/ieee80211/Kconfig b/net/ieee80211/Kconfig index dbb08528ddf5..f7e84e9d13ad 100644 --- a/net/ieee80211/Kconfig +++ b/net/ieee80211/Kconfig | |||
@@ -58,6 +58,7 @@ config IEEE80211_CRYPT_TKIP | |||
58 | depends on IEEE80211 && NET_RADIO | 58 | depends on IEEE80211 && NET_RADIO |
59 | select CRYPTO | 59 | select CRYPTO |
60 | select CRYPTO_MICHAEL_MIC | 60 | select CRYPTO_MICHAEL_MIC |
61 | select CRC32 | ||
61 | ---help--- | 62 | ---help--- |
62 | Include software based cipher suites in support of IEEE 802.11i | 63 | Include software based cipher suites in support of IEEE 802.11i |
63 | (aka TGi, WPA, WPA2, WPA-PSK, etc.) for use with TKIP enabled | 64 | (aka TGi, WPA, WPA2, WPA-PSK, etc.) for use with TKIP enabled |
diff --git a/net/ieee80211/softmac/ieee80211softmac_auth.c b/net/ieee80211/softmac/ieee80211softmac_auth.c index ebc33ca6e692..4cef39e171d0 100644 --- a/net/ieee80211/softmac/ieee80211softmac_auth.c +++ b/net/ieee80211/softmac/ieee80211softmac_auth.c | |||
@@ -116,6 +116,16 @@ ieee80211softmac_auth_queue(void *data) | |||
116 | kfree(auth); | 116 | kfree(auth); |
117 | } | 117 | } |
118 | 118 | ||
119 | /* Sends a response to an auth challenge (for shared key auth). */ | ||
120 | static void | ||
121 | ieee80211softmac_auth_challenge_response(void *_aq) | ||
122 | { | ||
123 | struct ieee80211softmac_auth_queue_item *aq = _aq; | ||
124 | |||
125 | /* Send our response */ | ||
126 | ieee80211softmac_send_mgt_frame(aq->mac, aq->net, IEEE80211_STYPE_AUTH, aq->state); | ||
127 | } | ||
128 | |||
119 | /* Handle the auth response from the AP | 129 | /* Handle the auth response from the AP |
120 | * This should be registered with ieee80211 as handle_auth | 130 | * This should be registered with ieee80211 as handle_auth |
121 | */ | 131 | */ |
@@ -197,24 +207,30 @@ ieee80211softmac_auth_resp(struct net_device *dev, struct ieee80211_auth *auth) | |||
197 | case IEEE80211SOFTMAC_AUTH_SHARED_CHALLENGE: | 207 | case IEEE80211SOFTMAC_AUTH_SHARED_CHALLENGE: |
198 | /* Check to make sure we have a challenge IE */ | 208 | /* Check to make sure we have a challenge IE */ |
199 | data = (u8 *)auth->info_element; | 209 | data = (u8 *)auth->info_element; |
200 | if(*data++ != MFIE_TYPE_CHALLENGE){ | 210 | if (*data++ != MFIE_TYPE_CHALLENGE) { |
201 | printkl(KERN_NOTICE PFX "Shared Key Authentication failed due to a missing challenge.\n"); | 211 | printkl(KERN_NOTICE PFX "Shared Key Authentication failed due to a missing challenge.\n"); |
202 | break; | 212 | break; |
203 | } | 213 | } |
204 | /* Save the challenge */ | 214 | /* Save the challenge */ |
205 | spin_lock_irqsave(&mac->lock, flags); | 215 | spin_lock_irqsave(&mac->lock, flags); |
206 | net->challenge_len = *data++; | 216 | net->challenge_len = *data++; |
207 | if(net->challenge_len > WLAN_AUTH_CHALLENGE_LEN) | 217 | if (net->challenge_len > WLAN_AUTH_CHALLENGE_LEN) |
208 | net->challenge_len = WLAN_AUTH_CHALLENGE_LEN; | 218 | net->challenge_len = WLAN_AUTH_CHALLENGE_LEN; |
209 | if(net->challenge != NULL) | 219 | if (net->challenge != NULL) |
210 | kfree(net->challenge); | 220 | kfree(net->challenge); |
211 | net->challenge = kmalloc(net->challenge_len, GFP_ATOMIC); | 221 | net->challenge = kmalloc(net->challenge_len, GFP_ATOMIC); |
212 | memcpy(net->challenge, data, net->challenge_len); | 222 | memcpy(net->challenge, data, net->challenge_len); |
213 | aq->state = IEEE80211SOFTMAC_AUTH_SHARED_RESPONSE; | 223 | aq->state = IEEE80211SOFTMAC_AUTH_SHARED_RESPONSE; |
214 | spin_unlock_irqrestore(&mac->lock, flags); | ||
215 | 224 | ||
216 | /* Send our response */ | 225 | /* We reuse the work struct from the auth request here. |
217 | ieee80211softmac_send_mgt_frame(mac, aq->net, IEEE80211_STYPE_AUTH, aq->state); | 226 | * It is safe to do so as each one is per-request, and |
227 | * at this point (dealing with authentication response) | ||
228 | * we have obviously already sent the initial auth | ||
229 | * request. */ | ||
230 | cancel_delayed_work(&aq->work); | ||
231 | INIT_WORK(&aq->work, &ieee80211softmac_auth_challenge_response, (void *)aq); | ||
232 | schedule_work(&aq->work); | ||
233 | spin_unlock_irqrestore(&mac->lock, flags); | ||
218 | return 0; | 234 | return 0; |
219 | case IEEE80211SOFTMAC_AUTH_SHARED_PASS: | 235 | case IEEE80211SOFTMAC_AUTH_SHARED_PASS: |
220 | kfree(net->challenge); | 236 | kfree(net->challenge); |