aboutsummaryrefslogtreecommitdiffstats
path: root/package/wificonf/wificonf.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2005-11-13 14:41:06 +0000
committerFelix Fietkau <nbd@openwrt.org>2005-11-13 14:41:06 +0000
commitcca7ee1254b646679bb862337b4781348fe9b53d (patch)
tree4b810ff428a580bace36c682a75437dfee1f3c37 /package/wificonf/wificonf.c
parent69325a4fbd33e1172b7e1f786662415f21db1824 (diff)
downloadupstream-cca7ee1254b646679bb862337b4781348fe9b53d.tar.gz
upstream-cca7ee1254b646679bb862337b4781348fe9b53d.tar.bz2
upstream-cca7ee1254b646679bb862337b4781348fe9b53d.zip
enable driver-internal supplicant only in wet mode and set psk2 mode if configured
git-svn-id: svn://svn.openwrt.org/openwrt/trunk/openwrt@2472 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/wificonf/wificonf.c')
-rw-r--r--package/wificonf/wificonf.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/package/wificonf/wificonf.c b/package/wificonf/wificonf.c
index 1867ed03f8..1ca1e5eb58 100644
--- a/package/wificonf/wificonf.c
+++ b/package/wificonf/wificonf.c
@@ -406,14 +406,13 @@ static void setup_bcom(int skfd, char *ifname)
bcom_ioctl(skfd, ifname, WLC_SET_WSEC, &val, sizeof(val));
if (val && strstr(v, "psk")) {
+ val = (strstr(v, "psk2") ? 0x84 : 0x4);
v = nvram_safe_get(wl_var("wpa_psk"));
-
if ((strlen(v) >= 8) && (strlen(v) < 63)) {
- val = 4;
+
bcom_ioctl(skfd, ifname, WLC_SET_WPA_AUTH, &val, sizeof(val));
- bcom_ioctl(skfd, ifname, WLC_GET_AP, &val, sizeof(val));
- if (!val) {
+ if (!nvram_match(wl_var("mode"), "wet")) {
/* Enable in-driver WPA supplicant */
wsec_pmk_t pmk;