mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2024-12-24 18:13:21 +02:00
[package] mac80211: fix wpa handling in sta mode
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@18662 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
0f5ab576f2
commit
a4827cab1f
@ -176,10 +176,10 @@ enable_mac80211() {
|
||||
case "$enc" in
|
||||
wep)
|
||||
config_get keymgmt "$vif" keymgmt
|
||||
if [ -e "$keymgmt" ]; then
|
||||
if [ -n "$keymgmt" ]; then
|
||||
for idx in 1 2 3 4; do
|
||||
local zidx
|
||||
zidx = idx - 1
|
||||
zidx = $((idx - 1))
|
||||
config_get key "$vif" "key${idx}"
|
||||
if [ -n "$key" ]; then
|
||||
append keystring "${zidx}:${key} "
|
||||
@ -187,7 +187,7 @@ enable_mac80211() {
|
||||
done
|
||||
fi
|
||||
;;
|
||||
wpa)
|
||||
*wpa*|*psk*)
|
||||
config_get key "$vif" key
|
||||
;;
|
||||
esac
|
||||
@ -240,7 +240,7 @@ enable_mac80211() {
|
||||
config_get bssid "$vif" bssid
|
||||
case "$enc" in
|
||||
wep)
|
||||
if [ -e "$keymgmt" ]; then
|
||||
if [ -n "$keymgmt" ]; then
|
||||
[ -n "$keystring" ] &&
|
||||
iw dev "$ifname" connect "$ssid" ${fixed:+$freq} $bssid key "$keystring"
|
||||
else
|
||||
@ -254,7 +254,7 @@ enable_mac80211() {
|
||||
fi
|
||||
fi
|
||||
;;
|
||||
wpa*|psk*)
|
||||
*wpa*|*psk*)
|
||||
config_get key "$vif" key
|
||||
if eval "type wpa_supplicant_setup_vif" 2>/dev/null >/dev/null; then
|
||||
wpa_supplicant_setup_vif "$vif" wext || {
|
||||
|
Loading…
Reference in New Issue
Block a user