From f3b0dcc3b596f23d91a7161a539247bb9b846457 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Mon, 22 Apr 2013 11:57:12 +0200 Subject: allow the use of WEP --- package/base-files/src/etc/network/if-pre-up.d/04-wireless | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'package/base-files/src') diff --git a/package/base-files/src/etc/network/if-pre-up.d/04-wireless b/package/base-files/src/etc/network/if-pre-up.d/04-wireless index ebcec5a12..030502efc 100755 --- a/package/base-files/src/etc/network/if-pre-up.d/04-wireless +++ b/package/base-files/src/etc/network/if-pre-up.d/04-wireless @@ -90,8 +90,11 @@ case "$IF_WIRELESS_MODE" in exit 1 } driver=nl80211 - iw dev ${IFACE} set channel $IF_WIRELESS_CHANNEL - iw dev ${IFACE} connect $IF_WIRELESS_SSID + [ $sec -eq 2 ] && { + iw dev ${IFACE} connect $IF_WIRELESS_SSID key d:0:$IF_WIRELESS_PASSPHRASE + } || { + iw dev ${IFACE} connect $IF_WIRELESS_SSID + } } [ $wpa2 -eq 1 ] && { [ -x /usr/sbin/wpa_supplicant ] || { -- cgit v1.2.3