* gnome/applet/nm-gconf-wso-wpa-psk.c, gnome/applet/nm-gconf-wso.c,
gnome/applet/wireless-security-option.c, include/NetworkManager.h,
libnm-util/cipher-wpa-psk-hex.c, src/nm-ap-security-wpa-psk.c,
libnm-util/cipher-wpa-psk-passphrase.c, src/nm-ap-security.c: Add
support for "Automatic" pairwise and group cipher configuration by
letting wpa_supplicant handle the details. Add UI elements, new
cipher type NM_AUTH_CIPHER_AUTO, and backend support. Works like a
charm. Note this does more than add a nice feature, it fixes a bug.
Apparently, some people have AP's where the pairwise cipher does not
match the group cipher. Insane, but true.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1407 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* gnome/applet/applet-dbus-devices.c
- (nmwa_dbus_device_get_driver_cb, nmwa_dbus_device_get_driver): new
functions, grab device driver name from NetworkManager
- (nmwa_dbus_device_properties_cb): call functions to get driver
* gnome/applet/applet.c
- (nmwa_update_info): show driver name in Connection Information
dialog
* gnome/applet/nm-device.[ch]
- (network_device_get_driver, network_device_set_driver): add
accessors for driver name
* gnome/applet/wireless-applet.glade
- Add line for driver name to Connection Information dialog
* src/nm-dbus-device.c
- (nm_dbus_device_get_driver): new function to return driver name
- (nm_dbus_device_methods): hook up driver name function to dbus
* test/nm-tool.c
- (get_driver_name): new function
- (detail_device): grab and show driver name
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1406 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* configure.in: Require wpa_supplicant. Detect location of binary and
use it. Override with "--with-wpa_supplicant=foo".
* src/Makefile.am, src/nm-device-802-11-wireless.c: Do not hardcode the
path to wpa_supplicant but use the auto-detected or user-provided
value from configure.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1399 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/backends/NetworkManagerSuSE.c: If DHCLIENT_SET_HOSTNAME is set
but the DHCP server did not return a hostname, try to look up our
name via DNS and set the system hostname to that.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1398 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/Makefile.am, src/kernel-types.h: Now that two different source
files are feeling the crack-addled leakage of kernel types such as
u32 and s8 -- superior to __u64 and __u8, to be sure, but not valid
types in user-space -- define a header and include it as needed.
* src/nm-device-802-3-ethernet.c: Include kernel-types.h
* src/nm-device-802-3-ethernet.h: Remove defines.
* src/wpa.c: Remove defines and include kernel-types.h.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1393 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/NetworkManagerAP.[ch]
- (nm_ap_new_from_ap): copy original essid too
- (nm_ap_unref): free original essid
- (nm_ap_get_orig_essid): new function
- (nm_ap_set_essid): Convert essid to UTF-8 for display and dbus,
but keep original essid around too
* src/nm-device-802-11-wireless.c
- (supplicant_send_network_config): send wpa_supplicant the
_original_ essid, and not as a string, but in hex. Should
allow us to connect to more APs that use wierd character
encodings for their essids
* utils/nm-utils.[ch]
- (nm_utils_essid_to_utf8): make a best-effort to convert the essid
to UTF-8. If it's not already valid UTF-8, we check LANG and
use the current locale as a hint for what encoding the essid
might be in. Obviously not 100% accurate, but the idea here is
that if a user's locale is ex. ja_JP, they are more likely than
not to be in Japan, where access points will likely be in some
Japanese encoding.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1385 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* dhcp-manager/nm-dhcp-manager.c, nm-device.c, nm-ip4-config.c,
nm-ip4-config.h, NetworkManagerSystem.h: Save the hostname reported
by DHCP and pass it to the backends, allowing distribution-specific
behavior with respect to the DHCP-supplied hostname (if nothing else,
some distributions might not want to set the hostname).
* backends/NetworkManagerSuSE.c: Set the hostname if the variable
DHCLIENT_SET_HOSTNAME is set to "yes" in /etc/sysconfig/network/dhcp.
Also update our NIS behavior.
* backends/NetworkManagerDebian.c, backends/NetworkManagerGentoo.c,
backends/NetworkManagerRedHat.c, backends/NetworkManagerSlackware.c:
Add stub functions.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1382 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/NetworkManagerAP.[ch]
- (nm_ap_get_matched, nm_ap_set_matched): remove
* src/NetworkManagerAPList.[ch]
- (nm_ap_list_diff): removed
- (nm_ap_list_merge_scanned_ap): move AP dbus signal logic here,
deal with access points changing essids on us
* src/nm-device-802-11-wireless.c
- (add_new_ap_to_device_list): move AP dbus signal logic to
src/NetworkManagerAPList.c
- (real_can_interrupt_activation): new function; allow interruption
of device activation if we are waiting for a network key
* src/NetworkManagerPolicy.c
- (nm_policy_device_change_check): allow interruption of currently
activating devices if the device allows it. Previous behavior
would refuse to activate a just-plugged wired device if a
wireless device was waiting for a key.
* src/nm-device.[ch]
- (nm_device_can_interrupt_activation): new function; ask devices
whether their activation can be interrupted
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1375 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/NetworkManagerDbus.c: Fail if NM's DBUS service is already taken,
instead of queuing. This prevents the running of multiple NM
daemons concurrently, which does not work whatsoever and results in
neither daemon working correctly. Also, we don't handle queuing and
name-owner-changes, anyhow.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1364 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/Makefile.am: Install the NetworkManager daemon to sbin, not bin.
* dispatcher/Makefile.am: Install the NetworkManagerDispatcher daemon
to sbin, not bin.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1363 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/NetworkManager.c, src/NetworkManagerSystem.h, src/nm-device.c:
Allow backends to flag a device (in whatever distro-dependent way
they so desire) as disabled. NM will ignore any such device.
* src/backends/NetworkManagerDebian.c,
src/backends/NetworkManagerRedHat.c,
src/backends/NetworkManagerSlackware.c: Add stub function
nm_system_device_get_disabled() that always returns FALSE (enabled).
* src/backends/NetworkManagerSuSE.c: Add system_disabled field to the
SUSE-specific configuration structure. Fill it in from the
NM_CONTROLLED variable in the system networking scripts. If this var
exists and is "no", we ignore the device.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1361 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/Makefile.am: Don't install NMLoadModules
* src/NMLoadModules, test/NMLoadModules: Move the NMLoadModules script
from src/ to test/ as no one uses it anymore. Note that I would be
fine with removing it altogether.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1353 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Apply the PtP Address bits of a patch from Tim Niemueller
* src/nm-ip4-config.[ch]
- Add ip4_ptp_address member to object
- (nm_ip4_config_copy): copy ptp address too
- (nm_ip4_config_get_ptp_address, nm_ip4_config_set_ptp_address):
new functions
- (nm_ip4_config_to_rtnl_addr): use ptp address when asked to,
rather than local tunnel ip address
* src/vpn-manager/nm-vpn-service.c
- (print_vpn_config): update for PtP address
- (nm_vpn_service_stage4_ip_config_get): switch parsing to
DBusMessageIters in preparation for getting routes from the VPN
service daemons too
* vpn-daemons/openvpn/src/nm-openvpn-service-openvpn-helper.c
- (send_config_info): update for PtP address, clean up code
- (main): update for PtP address, clean up code, fix typo
* vpn-daemons/openvpn/src/nm-openvpn-service.c
- (nm_openvpn_dbus_process_helper_ip4_config): update for PtP address
* vpn-daemons/pptp/src/nm-pptp-service-pppd-plugin.c
- (pptp_ip_up): update for PtP address
* vpn-daemons/pptp/src/nm-pptp-service.c
- (nm_pptp_dbus_process_helper_ip4_config): update for PtP address
* vpn-daemons/vpnc/src/nm-vpnc-service.c
- (print_vpn_config): update for PtP address
- (nm_vpnc_dbus_process_helper_ip4_config): update for PtP address
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1346 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device.c
src/nm-device.h
- Allow subclasses to implement deactivate_quickly()
- (nm_device_deactivate_quickly): call subclass
deactivate_quickly() methods
- (nm_device_set_active_link): small cleanups, and don't
deactivate the device right away because we risk a deadlock
when called from device thread, waiting for the device
thread to cancel activation
* src/nm-device-802-11-wireless.c
- (real_deactivate_quickly): new function
- (nm_device_802_11_wireless_class_init): hook in real_deactivate_quickly
- (real_deactivate): move supplicant cleanup to real_deactivate_quickly
so that we kill the supplicant when we sleep too
- (supplicant_interface_init): work around naive naming attempts of
wpa_ctrl when naming sockets
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1326 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-802-11-wireless.c
- (supplicant_cleanup): delete old device control sockets too
- (supplicant_get_device_socket_path): new function to consolidate
locations that need a path to a device's control socket
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1325 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/backends/NetworkManagerSuSE.c: Put the ppp device in the
description so that the description is unique for each
pair (device,provider). Fixes Novell #142773.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1324 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-802-3-ethernet.c: In case local copies of glibc do not
define if_mii(), open code the same results, and do so without any
type punning.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1320 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Add options for WPA2 and WPA1+CCMP (AES).
* gnome/applet/wireless-applet.glade
- Add UI bits for WPA+CCMP
* gnome/applet/other-network-dialog.c
- (nmwa_ond_init): pass capabilities into the WirelessSecurityManager,
and don't allow creation of WPA2 Ad-Hoc networks since
wpa_supplicant doesn't support them
* gnome/applet/wireless-security-manager.c
- (wsm_set_capabilities): Add WPA2 options, and pass capability
on to the specific wireless security option being created
* gnome/applet/wireless-security-option.[ch]
- (wso_wpa_create_key_type_model): new utility function to create
the model required for WPA Key Type combo box
* gnome/applet/wso-private.h
gnome/applet/wireless-security-option.h
- Move private function prototypes into wso-private.h
* gnome/applet/wso-wpa-psk-hex.[ch]
gnome/applet/wso-wpa-psk-passphrase.[ch]
- (append_dbus_params_func): get WPA version from checkbox and pass
it to the dbus serialization helper
- (key_type_combo_changed_cb): Set the cipher's WE Cipher when the
key type combo changes
- (wso_wpa_psk_hex_new): set up the key type combo with the correct
model and options
* libnm-util/cipher-wpa-psk-hex.c
libnm-util/cipher-wpa-psk-passphrase.c
- (cipher_wpa_psk_hex_set_we_cipher, cipher_wpa_psk_passphrase_set_we_cipher):
new function; allow the cipher to be changed after object creation
* src/nm-ap-security-wpa-psk.c
- (set_description): Do WPA2 descriptions too
* src/nm-ap-security.c
- (nm_ap_security_new_from_ap): allow CCMP with WPA1 too
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1317 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-802-3-ethernet.c: Use the if_mii() inline function that
is defined in <linux/mii.h> to return the mii_ioctl_data structure
from the ifreq structure in lieu of an open coded solution. Removes
a life-threatening type-punning.
* configure.in: Remove '-Wno-strict-aliasing' as we no longer pun any
types, ever, whatsoever, baby.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1316 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-802-11-wireless.c, src/nm-device-802-11-wireless.h,
src/nm-device-802-3-ethernet.c, src/nm-device-802-3-ethernet.h,
src/nm-device.c: Fix a FIXME! Reimplement the function
nm_device_update_hw_address() in device subclass variants,
nm_device_802_3_ethernet_set_address() and
nm_device_802_11_wireless_set_address(), hook them up, and use them.
This fixes the existing bug where MAC addresses are all zeros.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1309 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-802-3-ethernet.h: The kernel headers <linux/mii.h> and
<linux/ethtool.h> leak the kernel-only types u16, u32, et al.
User-space does not supply these types, so we have to define them
ourselves. The relevant kernel maintainer refused to accept a patch
switching these headers to the propre C99 types.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1304 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/NetworkManagerPolicy.c
- (nm_policy_device_change_check): don't autoswitch away from
Ad-Hoc networks, since there's really no concept of "link"
* src/nm-dbus-nm.c
- (nm_dbus_nm_create_wireless_network): mark created networks
as Ad-Hoc networks
* src/nm-device-802-11-wireless.c
- (real_activation_success_handler): add user-created Ad-Hoc
networks to the device's scan list
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1300 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-ap-security.c
src/nm-ap-security.h
- Add a user_created argument to the write_supplicant_config
functions
* src/nm-ap-security-wep.c
src/nm-ap-security-wpa-psk.c
src/nm-device-802-11-wireless.c
- Make Ad-Hoc mode somewhat work, at least write the
correct options to wpa_supplicant
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1298 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* include/NetworkManager.h
- Add NMI_DBUS_USER_KEY_CANCELED_ERROR as a constant for
applet/info-daemons
* gnome/applet/passphrase-dialog.c
- Use the constant. Fixes a bug where the arguments to
dbus_message_new_error() were incorrect
* src/nm-dbus-nmi.c
- Use the constant
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@1289 4912f4e0-d625-0410-9fb7-b9a5a253dbdc