2007-09-21 Dan Williams <dcbw@redhat.com>

* src/nm-device-802-11-wireless.c
		- (build_supplicant_config): wpa_supplicant requires the option
			key_mgmt=NONE for unencrypted networks
		- (real_act_stage2_config): clarify log message on activation



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2852 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
Dan Williams 2007-09-22 03:25:26 +00:00
parent 93b6fcea47
commit 03e118462b
2 changed files with 32 additions and 8 deletions

View file

@ -1,3 +1,10 @@
2007-09-21 Dan Williams <dcbw@redhat.com>
* src/nm-device-802-11-wireless.c
- (build_supplicant_config): wpa_supplicant requires the option
key_mgmt=NONE for unencrypted networks
- (real_act_stage2_config): clarify log message on activation
2007-09-21 Dan Williams <dcbw@redhat.com>
* test/nm-supplicant-test.c

View file

@ -2357,11 +2357,20 @@ build_supplicant_config (NMDevice80211Wireless *self,
}
s_wireless_sec = (NMSettingWirelessSecurity *) nm_connection_get_setting (connection, "802-11-wireless-security");
if ( s_wireless_sec
&& !nm_supplicant_config_add_setting_wireless_security (config,
s_wireless_sec)) {
nm_warning ("Couldn't add 802-11-wireless-security setting to supplicant config.");
goto error;
if (s_wireless_sec) {
if (!nm_supplicant_config_add_setting_wireless_security (config,
s_wireless_sec)) {
nm_warning ("Couldn't add 802-11-wireless-security setting to "
"supplicant config.");
goto error;
}
} else {
/* Unencrypted, wpa_supplicant needs key_mgmt=NONE here */
if (!nm_supplicant_config_add_option (config, "key_mgmt", "NONE", -1, FALSE)) {
nm_warning ("Couldn't add 802-11-wireless (no security) setting to"
" supplicant config.");
goto error;
}
}
return config;
@ -2478,9 +2487,17 @@ real_act_stage2_config (NMDevice *dev)
setting_name);
return NM_ACT_STAGE_RETURN_POSTPONE;
} else {
nm_info ("Activation (%s/wireless): connection '%s' has security"
", and secrets exist. No new secrets needed.",
iface, s_connection->name);
NMSettingWireless *s_wireless = (NMSettingWireless *) nm_connection_get_setting (connection, NM_SETTING_WIRELESS);
if (s_wireless->security) {
nm_info ("Activation (%s/wireless): connection '%s' has security"
", and secrets exist. No new secrets needed.",
iface, s_connection->name);
} else {
nm_info ("Activation (%s/wireless): connection '%s' requires no "
"security. No secrets needed.",
iface, s_connection->name);
}
}
config = build_supplicant_config (self, connection, ap);