Re: WPA2 Enterprise (and other things)



Dan Williams <dcbw <at> redhat.com> writes:

> See if the applet gets the key required dbus method call, the code for
> which is probably in applet-dbus-info.c.  The applet is supposed (1) to
> serve that info from the gnome-keyring, or (2) if it doesn't find it
> there, pop up a dialog to get it.  If (1), it returns the key in the
> dbus pending call, and NM's callback should be entered.  If (2), when
> the user hits the OK button in the dialog, it should return the key to
> NM, and NM's callback should be entered.
> 
> Dan
> 

Perfect, thanks! Found & fixed two issues in the applet & now working.. ;)

1. nm_gconf_wso_new_deserialize_gconf() was missing the case for EAP

2. nm_gconf_wso_wpa_eap_new_deserialize_gconf() was error checking each entry,
but not all are required. I've removed the checks from all, but there may be a
better middle-ground.. 

Patch follows inline (can't post as an attachment from here - so can only
apologise if the formatting gets messed up)

Regards,
Jon.

diff -urN NetworkManager.orig/gnome/applet/nm-gconf-wso.c
NetworkManager.patched/gnome/applet/nm-gconf-wso.c
--- NetworkManager.orig/gnome/applet/nm-gconf-wso.c	2006-02-26
02:16:52.000000000 +0000
+++ NetworkManager.patched/gnome/applet/nm-gconf-wso.c	2006-03-24
14:18:29.000000000 +0000
@@ -137,6 +137,10 @@
 				security = NM_GCONF_WSO (nm_gconf_wso_wpa_psk_new_deserialize_gconf
(client, network, we_cipher));
 				break;
 
+			case NM_AUTH_TYPE_WPA_EAP:
+				security = NM_GCONF_WSO (nm_gconf_wso_wpa_eap_new_deserialize_gconf
(client, network, we_cipher));
+				break;
+
 			default:
 				break;
 		}
diff -urN NetworkManager.orig/gnome/applet/nm-gconf-wso-wpa-eap.c
NetworkManager.patched/gnome/applet/nm-gconf-wso-wpa-eap.c
--- NetworkManager.orig/gnome/applet/nm-gconf-wso-wpa-eap.c	2006-03-22
19:52:40.000000000 +0000
+++ NetworkManager.patched/gnome/applet/nm-gconf-wso-wpa-eap.c	2006-03-24
14:10:52.000000000 +0000
@@ -106,90 +106,80 @@
 	char *			private_key_file = NULL;
 	char *			client_cert_file = NULL;
 	char *			ca_cert_file = NULL;
-	int				wpa_version;
-	int				eap_method;
-	int				key_type;
-	int				key_mgmt;
+	int				wpa_version = 0;
+	int				eap_method = 0;
+	int				key_type = 0;
+	int				key_mgmt = 0;
 
 	g_return_val_if_fail (client != NULL, NULL);
 	g_return_val_if_fail (network != NULL, NULL);
 	g_return_val_if_fail ((we_cipher == NM_AUTH_TYPE_WPA_EAP), NULL);
 
-	if (!nm_gconf_get_int_helper (client,
+	nm_gconf_get_int_helper (client,
 							GCONF_PATH_WIRELESS_NETWORKS,
 							WPA_EAP_PREFIX"eap_method",
 							network,
-							&eap_method))
-		goto out;
+							&eap_method);
 
-	if (!nm_gconf_get_int_helper (client,
+	nm_gconf_get_int_helper (client,
 							GCONF_PATH_WIRELESS_NETWORKS,
 							WPA_EAP_PREFIX"key_type",
 							network,
-							&key_type))
-		goto out;
+							&key_type);





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]