mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-02-04 02:30:24 +01:00
2006-01-06 Robert Love <rml@novell.com>
* gnome/applet/applet-dbus-devices.c, gnome/applet/other-network-dialog.c, gnome/applet/wso-none.c, libnm-util/dbus-helpers.c, libnm-util/dbus-helpers.h, src/nm-dbus-nm.c: Fix several issues. 'Connect to Other' and 'Create New Network' both failed in the non-encrypted case because we were not appending the security options to the DBUS message. And 'Connect to Other' was also failing in the encrypted case because we were not incrementing to the next DBUS parameter. All fixed. Thanks to dcdw for some debugging help. git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1276 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
This commit is contained in:
parent
d8e4dcb4a5
commit
22e8b28790
7 changed files with 39 additions and 4 deletions
12
ChangeLog
12
ChangeLog
|
|
@ -1,3 +1,15 @@
|
|||
2006-01-06 Robert Love <rml@novell.com>
|
||||
|
||||
* gnome/applet/applet-dbus-devices.c,
|
||||
gnome/applet/other-network-dialog.c, gnome/applet/wso-none.c,
|
||||
libnm-util/dbus-helpers.c, libnm-util/dbus-helpers.h,
|
||||
src/nm-dbus-nm.c: Fix several issues. 'Connect to Other' and 'Create
|
||||
New Network' both failed in the non-encrypted case because we were
|
||||
not appending the security options to the DBUS message. And
|
||||
'Connect to Other' was also failing in the encrypted case because
|
||||
we were not incrementing to the next DBUS parameter. All fixed.
|
||||
Thanks to dcdw for some debugging help.
|
||||
|
||||
2006-01-06 Robert Love <rml@novell.com>
|
||||
|
||||
* gnome/applet/applet-dbus-devices.c, gnome/applet/applet.c,
|
||||
|
|
|
|||
|
|
@ -1134,7 +1134,7 @@ void nmwa_dbus_set_device (DBusConnection *connection, NetworkDevice *dev, const
|
|||
DBUS_TYPE_STRING, &essid,
|
||||
DBUS_TYPE_INVALID);
|
||||
|
||||
/* If we've got specific wireless security options, add them */
|
||||
/* If we have specific wireless security options, add them */
|
||||
if (opt)
|
||||
success = wso_append_dbus_params (opt, essid, message);
|
||||
}
|
||||
|
|
@ -1181,11 +1181,12 @@ void nmwa_dbus_create_network (DBusConnection *connection, NetworkDevice *dev, c
|
|||
DBUS_TYPE_INVALID);
|
||||
wso_append_dbus_params (opt, essid, message);
|
||||
dbus_connection_send (connection, message, NULL);
|
||||
}
|
||||
} else
|
||||
nm_warning ("nmwa_dbus_create_network(): Could not get the device path!\n");
|
||||
dbus_message_unref (message);
|
||||
}
|
||||
else
|
||||
nm_warning ("nmwa_dbus_set_device(): Couldn't allocate the dbus message\n");
|
||||
nm_warning ("nmwa_dbus_create_network(): Couldn't allocate the dbus message\n");
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
|
|
@ -434,6 +434,7 @@ static void nmwa_ond_response_cb (GtkDialog *dialog, gint response, gpointer dat
|
|||
destroy_wireless_adapter_model (model);
|
||||
}
|
||||
|
||||
|
||||
void nmwa_other_network_dialog_run (NMWirelessApplet *applet, gboolean create_network)
|
||||
{
|
||||
GtkDialog * dialog;
|
||||
|
|
|
|||
|
|
@ -25,6 +25,7 @@
|
|||
#include "wso-none.h"
|
||||
#include "wso-private.h"
|
||||
#include "cipher.h"
|
||||
#include "dbus-helpers.h"
|
||||
|
||||
|
||||
static gboolean validate_input_func (WirelessSecurityOption *opt, const char *ssid, IEEE_802_11_Cipher ** out_cipher)
|
||||
|
|
@ -38,6 +39,7 @@ static gboolean append_dbus_params_func (WirelessSecurityOption *opt, const char
|
|||
{
|
||||
g_return_val_if_fail (opt != NULL, FALSE);
|
||||
|
||||
nmu_security_serialize_none_with_cipher (message);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -94,6 +94,23 @@ nmu_security_deserialize_wep (DBusMessageIter *iter,
|
|||
}
|
||||
|
||||
|
||||
dbus_bool_t
|
||||
nmu_security_serialize_none_with_cipher (DBusMessage *message)
|
||||
{
|
||||
dbus_bool_t result = TRUE;
|
||||
DBusMessageIter iter;
|
||||
|
||||
g_return_val_if_fail (message != NULL, FALSE);
|
||||
|
||||
dbus_message_iter_init_append (message, &iter);
|
||||
|
||||
/* First arg: WE Cipher (INT32) */
|
||||
we_cipher_append_helper (&iter, IW_AUTH_CIPHER_NONE);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
dbus_bool_t
|
||||
nmu_security_serialize_wep_with_cipher (DBusMessage *message,
|
||||
IEEE_802_11_Cipher *cipher,
|
||||
|
|
|
|||
|
|
@ -35,6 +35,8 @@ dbus_bool_t nmu_security_deserialize_wep (DBusMessageIter *iter,
|
|||
int *key_len,
|
||||
int *auth_alg);
|
||||
|
||||
dbus_bool_t nmu_security_serialize_none_with_cipher (DBusMessage *message);
|
||||
|
||||
dbus_bool_t nmu_security_serialize_wep_with_cipher (DBusMessage *message,
|
||||
IEEE_802_11_Cipher *cipher,
|
||||
const char *ssid,
|
||||
|
|
|
|||
|
|
@ -278,7 +278,7 @@ static DBusMessage *nm_dbus_nm_set_active_device (DBusConnection *connection, DB
|
|||
/* If there's security information, we use that. If not, we
|
||||
* make some up from the scan list.
|
||||
*/
|
||||
if (dbus_message_iter_has_next (&iter))
|
||||
if (dbus_message_iter_next (&iter))
|
||||
{
|
||||
if (!(security = nm_ap_security_new_deserialize (&iter)))
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue