aboutsummaryrefslogtreecommitdiffstats
path: root/package/madwifi/files/lib/wifi
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2007-03-24 01:01:18 +0000
committerFelix Fietkau <nbd@openwrt.org>2007-03-24 01:01:18 +0000
commit4a65dd20fe69b1017365028d9777cdbf739de870 (patch)
tree907bf2178454dae5bf49df119a7229ce9c5a3d74 /package/madwifi/files/lib/wifi
parent080d4f6710629125a483d7d78d3f9bd4794be022 (diff)
downloadupstream-4a65dd20fe69b1017365028d9777cdbf739de870.tar.gz
upstream-4a65dd20fe69b1017365028d9777cdbf739de870.tar.bz2
upstream-4a65dd20fe69b1017365028d9777cdbf739de870.zip
fix wep encryption setting for madwifi
SVN-Revision: 6655
Diffstat (limited to 'package/madwifi/files/lib/wifi')
-rwxr-xr-xpackage/madwifi/files/lib/wifi/madwifi.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/package/madwifi/files/lib/wifi/madwifi.sh b/package/madwifi/files/lib/wifi/madwifi.sh
index 720f3af87c..1cd727ade7 100755
--- a/package/madwifi/files/lib/wifi/madwifi.sh
+++ b/package/madwifi/files/lib/wifi/madwifi.sh
@@ -125,7 +125,11 @@ enable_atheros() {
iwconfig "$ifname" enc "[$idx]" "${key:-off}"
done
config_get key "$vif" key
- iwconfig "$ifname" enc "${key:-1}"
+ key="${key:-1}"
+ case "$key" in
+ [1234]) iwconfig "$ifname" enc "[$key]";;
+ *) iwconfig "$ifname" enc "$key";;
+ esac
;;
PSK|psk|PSK2|psk2)
config_get key "$vif" key