orinoco: fix TKIP countermeasure behaviour
commit2c3c5834eacf61a099f8c3add3baec04771326ca
authorDavid Kilroy <kilroyd@googlemail.com>
Sat, 4 Dec 2010 14:46:22 +0000 (4 14:46 +0000)
committerDavid Kilroy <kilroyd@googlemail.com>
Sat, 11 Dec 2010 15:26:51 +0000 (11 15:26 +0000)
tree20308747cd9ad82df2fd913b8bccc8a103618aac
parent1322cf5f15a35438673b6d7e5db7591e059c9a37
orinoco: fix TKIP countermeasure behaviour

Enable the port when disabling countermeasures, and disable it on
enabling countermeasures.

This bug causes the response of the system to certain attacks to be
ineffective.

It also prevents wpa_supplicant from getting scan results, as
wpa_supplicant disables countermeasures on startup - preventing the
hardware from scanning.

wpa_supplicant works with ap_mode=2 despite this bug because the commit
handler re-enables the port.

The log tends to look like:

State: DISCONNECTED -> SCANNING
Starting AP scan for wildcard SSID
Scan requested (ret=0) - scan timeout 5 seconds
EAPOL: disable timer tick
EAPOL: Supplicant port status: Unauthorized
Scan timeout - try to get results
Failed to get scan results
Failed to get scan results - try scanning again
Setting scan request: 1 sec 0 usec
Starting AP scan for wildcard SSID
Scan requested (ret=-1) - scan timeout 5 seconds
Failed to initiate AP scan.

Reported by: Giacomo Comes <comes@naic.edu>
Signed-off by: David Kilroy <kilroyd@googlemail.com>
drivers/net/wireless/orinoco/wext.c