diff options
author | Dan Williams <dcbw@redhat.com> | 2007-12-13 20:26:20 +0000 |
---|---|---|
committer | Dan Williams <dcbw@redhat.com> | 2007-12-13 20:26:20 +0000 |
commit | 86ddbca2e11178908c1277687f34b699dc4d18f6 (patch) | |
tree | d5b1346ab5f7765f756bddfd4993163baab25990 | |
parent | 588e1277e108b8475fee5de99ebc2f4c6ebe4a53 (diff) | |
download | NetworkManager-86ddbca2e11178908c1277687f34b699dc4d18f6.tar.gz |
2007-12-13 Dan Williams <dcbw@redhat.com>
* src/nm-ap-security-wep.c
- (real_write_supplicant_config): always set auth_alg appropriately
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/branches/nm-0-6-olpc@3170 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | src/nm-ap-security-wep.c | 18 |
2 files changed, 15 insertions, 8 deletions
@@ -1,3 +1,8 @@ +2007-12-13 Dan Williams <dcbw@redhat.com> + + * src/nm-ap-security-wep.c + - (real_write_supplicant_config): always set auth_alg appropriately + 2007-09-08 Dan Williams <dcbw@redhat.com> * src/nm-device-802-11-mesh-olpc.h diff --git a/src/nm-ap-security-wep.c b/src/nm-ap-security-wep.c index fcd806b3dc..46cf19a2f9 100644 --- a/src/nm-ap-security-wep.c +++ b/src/nm-ap-security-wep.c @@ -126,14 +126,16 @@ real_write_supplicant_config (NMAPSecurity *instance, "SET_NETWORK %i key_mgmt NONE", nwid)) goto out; - /* - * If the user selected "Shared" (aka restricted) key, set it explicitly. Otherwise, - * let wpa_supplicant default to the right thing, which is an open key. - */ - if (get_auth_algorithm (NM_AP_SECURITY_WEP (instance)) == IW_AUTH_ALG_SHARED_KEY) - { - if (!nm_utils_supplicant_request_with_check (ctrl, "OK", __func__, msg, - "SET_NETWORK %i auth_alg SHARED", nwid)); + switch (get_auth_algorithm (NM_AP_SECURITY_WEP (instance))) { + case IW_AUTH_ALG_SHARED_KEY: + nm_utils_supplicant_request_with_check (ctrl, "OK", __func__, msg, + "SET_NETWORK %i auth_alg SHARED", nwid); + break; + case IW_AUTH_ALG_OPEN_SYSTEM: + default: + nm_utils_supplicant_request_with_check (ctrl, "OK", __func__, msg, + "SET_NETWORK %i auth_alg OPEN", nwid); + break; } msg = g_strdup_printf ("SET_NETWORK %i wep_key0 <key>", nwid); |