Commit graph

1737 commits

Author SHA1 Message Date
Dan Williams 64f1a1d423 2008-07-09 Dan Williams <dcbw@redhat.com>
* callouts/Makefile.am
	  callouts/nm-avahi-autoipd-action.c
	  callouts/nm-avahi-autoipd.conf
		- avahi-autoipd callout to send options back to NM

	* src/autoip.c
	  src/autoip.h
		- remove

	* src/nm-device.c
	  src/nm-device-private.h
	  src/nm-manager.c
		- Use avahi-autoipd for IPv4LL functionality rather than really crappy
			old custom stuff



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3816 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-09 14:05:49 +00:00
Dan Williams e059e6176d 2008-07-07 Dan Williams <dcbw@redhat.com>
* system-settings/plugins/ifcfg-fedora/reader.c
		- (make_ip4_setting): handle DHCP_HOSTNAME; fix up prefix support to
			handle PREFIX too; clean up



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3815 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-07 19:30:53 +00:00
Dan Williams e1e4100f76 2008-07-07 Dan Williams <dcbw@redhat.com>
Convert to using IPv4 prefixes instead of netmasks.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3812 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-07 18:57:37 +00:00
Dan Williams 794c1880f2 2008-07-03 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting-ip4-config.c
	  libnm-util/nm-setting-ip4-config.h
		- Add properties for DHCP Client Identifier and DHCP Hostname

	* src/dhcp-manager/nm-dhcp-manager.c
	  src/dhcp-manager/nm-dhcp-manager.h
		- (nm_dhcp_manager_begin_transaction): take the connection's ip4-config
			setting as an argument to pass on to the dhclient config file
			creation function
		- (nm_dhcp_manager_cancel_transaction_real): remove dhclient config when
			DHCP is torn down
		- (dhclient_run): punt config file handling to create_dhclient_config()
		- (create_dhclient_config): create an interface-specific dhclient
			config file since there may need to be interface-specific options
			passed to dhclient
		- (merge_dhclient_config): merge normal distro dhclient config file and
			add options from the connection
		- (nm_dhcp_device_new): generate the interface specific dhclient
			config file path once
		- (nm_dhcp_device_destroy): handle partially initialized objects; free
			dhclient config file path

	* src/nm-device.c
		- (real_act_stage3_ip_config_start): pass ip4-config, if any, to the
			DHCP manager when starting DHCP



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3805 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-03 16:22:17 +00:00
Dan Williams a8a0c113a7 2008-07-02 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting-8021x.c
		- (verify): allow forcing the PEAP label to 0



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3800 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-02 16:08:04 +00:00
Dan Williams 5348be4d0b 2008-07-02 Dan Williams <dcbw@redhat.com>
* introspection/nm-active-connection.xml
	  introspection/nm-vpn-connection.xml
	  libnm-glib/nm-active-connection.c
	  src/nm-activation-request.c
	  src/nm-active-connection.h
	  src/vpn-manager/nm-vpn-connection.c
		- Remove "SharedServiceName" and "SharedConnection" bits from the D-Bus
			and libnm-glib API since sharing didn't get implemented that way



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3797 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-02 13:00:14 +00:00
Dan Williams 6f22c03c1b 2008-07-02 Dan Williams <dcbw@redhat.com>
* src/nm-device-wifi.c
		- (can_scan): don't scan when a shared connection is activated since
			that makes drivers mad (causing disconnects); also NM doesn't need
			to hedge against disconnects by keeping up-to-date network topology
			because the connection originates from the local machine, and thus
			there should be no disconnects



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3796 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-02 12:46:45 +00:00
Dan Williams 8c79f16f5d 2008-07-01 Dan Williams <dcbw@redhat.com>
Fix mobile broadband username/password issues.  NM was never requesting
	mobile broadband secrets, nor was it passing back the username and password
	if it had them.

	* marshallers/nm-marshal.list
		- Add some new types for activation request objects

	* src/nm-activation-request.c
	  src/nm-activation-request.h
		- (get_secrets_cb): pass the caller type in the signal
		- (nm_act_request_request_connection_secrets): take a caller type, so
			that GetSecrets() reply handlers know who asked for the secrets in
			the first place; use secret hints too so the settings service can
			figure out exactly what NM wants (ie, PIN or the PPP password)

	* src/ppp-manager/nm-ppp-manager.c
	  src/ppp-manager/nm-ppp-manager.h
		- (impl_ppp_manager_need_secrets): nm_connection_need_secrets() won't
			detect needed secrets when the secret could be blank, like GSM/CDMA
			passwords.  So always ask for secrets, and send a hint as to what
			secret we really want.
		- (nm_ppp_manager_update_secrets): make function more generic by making
			the device specific class figure out the username and password, and
			accept an error argument to return back over D-Bus

	* src/nm-device-wifi.c
		- (link_timeout_cb, handle_auth_or_fail): update for changes to
			nm_act_request_request_connection_secrets()
		- (real_connection_secrets_updated): update for 'caller' changes

	* src/nm-device.c
	  src/nm-device.h
		- (connection_secrets_updated_cb, connection_secrets_failed_cb): update
			for 'caller' changes

	* src/nm-device-ethernet.c
		- (real_connection_secrets_updated): update for 'caller' changes and
			move logic for getting PPPoE username and password here before
			calling nm_ppp_manager_update_secrets()
		- (link_timeout_cb, handle_auth_or_fail): update for changes to
			nm_act_request_request_connection_secrets()

	* src/nm-cdma-device.c
		- (real_connection_secrets_updated): pass username and password back
			to the PPP manager when required

	* src/nm-gsm-device.c
		- (enter_pin): send the required secret name to the settings service
		- (real_connection_secrets_updated): pass username and password back
			to the PPP manager when required



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3794 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-07-01 20:21:31 +00:00
Dan Williams 65758f7ffb 2008-06-30 Dan Williams <dcbw@redhat.com>
* src/nm-device-wifi.c
		- Consistently use NM_DEVICE_WIFI_GET_PRIVATE instead of self->priv



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3786 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-30 17:44:10 +00:00
Dan Williams 5c7c7da098 2008-06-30 Dan Williams <dcbw@redhat.com>
Attempt to fix various issues causing rh #448889.  Mainly, to qualify for
	the DISCONNECTED state, the device must not be rfkilled _and_ have a valid
	priv->supplicant.iface.  When either condition is false, the device should
	transition back to UNAVAILABLE because it cannot be used.

	* src/nm-device-wifi.c
		- (constructor): cleanup; connect to supplicant manager here since the
			supplicant manager is always around
		- (supplicant_interface_acquire): rename from init_supplicant_interface,
			ensure the supplicant manager is in the IDLE state
		- (supplicant_interface_release): rename from cleanup_supplicant_interface,
			cancel any pending scans too
		- (real_bring_up): don't set up the supplicnat interface here, because
			we need the supplicant interface at times when the device may not
			be "up"
		- (real_take_down): just remove the periodic source
		- (schedule_scan): ensure a state that would peg the CPU doesn't happen
		- (remove_supplicant_interface_connection_error_handler): cleanup; don't
			do anything if there's no supplicant interface
		- (cleanup_association_attempt): cleanup
		- (supplicant_iface_state_cb_handler): request an immediate scan when
			the interface enters the READY state; transition to UNAVAILABLE
			state when the interface goes down because the device can't be used
			without a supplicant interface
		- (supplicant_mgr_state_cb_handler): if the supplicant goes away, clean
			up and transition to UNAVAILABLE; if the supplicant becomes ready,
			acquire the supplicant interface and transition to DISCONNECTED
			if the radio isn't killed
		- (nm_device_wifi_dispose): move most of device_cleanup() here
		- (state_changed_cb): release any existing supplicant interface; if the
			radio is enabled then try to acquire a new supplicant interface;
			if the radio is enabled and a supplicant interface has been acquired,
			we can transition to DISCONNECTED
		- (nm_device_wifi_set_enabled): if bringing the hardware up failed,
			don't enable the radio, because HAL probably lied to us about the
			killswitch being off.  If bringing the hardware up worked, then
			try to grab a supplicant interface, and if that was successful,
			transition to DISCONNECTED



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3785 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-30 17:34:56 +00:00
Dan Williams 46e854c006 2008-06-30 Dan Williams <dcbw@redhat.com>
* src/supplicant-manager/nm-supplicant-interface.c
		- (request_scan_results, nm_supplicant_interface_dispose,
		   wpas_iface_query_scan_results): cleanup; scan_results_timeout is now
			the id of the timeout, not a GSource



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3784 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-30 17:12:11 +00:00
Tambet Ingo 571a013b69 2008-06-30 Tambet Ingo <tambet@gmail.com>
* src/backends/NetworkManagerSuSE.c (nm_system_activate_nis): Fix a
	bunch of typoes introduced by "Patch from David Cantrell
	<dcantrell@redhat.com> and me".


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3783 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-30 14:49:52 +00:00
Tambet Ingo 5cc268ab0e 2008-06-30 Tambet Ingo <tambet@gmail.com>
* src/nm-serial-device.c:
	* src/nm-gsm-device.c:
	* src/nm-cdma-device.c: Move the pending call handling to a common location
	in serial device. Handle setting device state to failed in one place as well.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3782 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-30 12:18:57 +00:00
Dan Williams 01ea95f444 2008-06-29 Dan Williams <dcbw@redhat.com>
* src/nm-hal-manager.c
		- Rework killswitch handling to query killswitch status immediately
			when the first killswitch is added, so that rfkill state is
			known as early as possible
		- Also treat failure of GetPower() as rfkill when the dbus method
			call times out (but not when the HAL callout returns an error)



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3781 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-29 15:46:31 +00:00
Dan Williams 5a516abc4b 2008-06-26 Dan Williams <dcbw@redhat.com>
Patch from David Cantrell <dcantrell@redhat.com> and me

	* include/nm-dbus-glib-types.h
		- Add IP6 address types

	* libnm-util/Makefile.am
	  libnm-util/nm-setting-ip6-config.c
	  libnm-util/nm-setting-ip6-config.h
		- Add IP6 settings object

	* libnm-util/nm-connection.c
		- (register_default_settings): register ip6 settings object

	* libnm-util/nm-utils.c
	  libnm-util/nm-utils.h
		- (nm_utils_ip6_addresses_from_gvalue, nm_utils_ip6_addresses_to_gvalue,
		   nm_utils_ip6_dns_from_gvalue, nm_utils_ip6_dns_to_gvalue): add
			ip6 address conversion functions



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3778 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-26 21:30:33 +00:00
Dan Williams dd0109ee28 2008-06-26 Dan Williams <dcbw@redhat.com>
Patch from David Cantrell <dcantrell@redhat.com>
	
	* Use inet_ntop() and inet_pton() everwhere and check for errors



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3777 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-26 19:33:13 +00:00
Dan Williams b0cf66eda8 2008-06-26 Dan Williams <dcbw@redhat.com>
* Update FSF address in license headers (Michael Biebl <biebl@debian.org>)



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3775 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-26 18:31:52 +00:00
Dan Williams 74158919b0 2008-06-26 Dan Williams <dcbw@redhat.com>
Patch from Adel Gadllah <adel.gadllah@gmail.com>

	* src/nm-device-wifi.c
		- (link_timeout_cb): don't ignore disconnects due to scanning
		- (supplicant_iface_connection_state_cb_handler): instead, schedule
			a longer timeout when scanning; avoids case where supplicant can't
			find the AP and just keeps scanning forever but isn't connected



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3774 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-26 17:53:35 +00:00
Dan Williams 8afd2d8ecd 2008-06-26 Dan Williams <dcbw@redhat.com>
Patch from Michael Biebl <biebl@debian.org>

	* Clean up build system stuff



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3773 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-26 17:34:04 +00:00
Christian Persch ab849b2beb * vpn-daemons/openvpn/auth-dialog/gnome-two-password-dialog.c:
* vpn-daemons/openvpn/auth-dialog/gnome-two-password-dialog.h:
	* vpn-daemons/pptp/auth-dialog-general/anonymous-auth-module.c:
	(impl_get_object):
	* vpn-daemons/pptp/auth-dialog-general/chap-auth-module.c:
	(impl_get_object):
	* vpn-daemons/pptp/auth-dialog-general/gnome-generic-auth-dialog.c:
	* vpn-daemons/pptp/auth-dialog-general/gnome-generic-auth-dialog.h:
	* vpn-daemons/pptp/auth-dialog-general/mschapv2-auth-module.c:
	(impl_get_object):
	* vpn-daemons/pptp/auth-dialog/gnome-two-password-dialog.c:
	* vpn-daemons/pptp/auth-dialog/gnome-two-password-dialog.h:
	* vpn-daemons/pptp/properties/nm-ppp-properties.c: (impl_setup):
	* vpn-daemons/pptp/properties/vpnui_impl.c: (impl_get_object):
	* vpn-daemons/pptp/properties/vpnui_opt.c:
	(vpnui_opt_connect_signals):
	* vpn-daemons/pptp/properties/vpnui_opt.h:
	* vpn-daemons/vpnc/auth-dialog/gnome-two-password-dialog.c:
	* vpn-daemons/vpnc/auth-dialog/gnome-two-password-dialog.h: Don't use
	deprecated gtk type macros. Bug #539325.

git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3764 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-23 15:24:40 +00:00
Dan Williams bdeeab3eda 2008-06-20 Dan Williams <dcbw@redhat.com>
* libnm-glib/nm-vpn-plugin-ui-interface.c
	  libnm-glib/nm-vpn-plugin-ui-interface.h
		- 'validity-changed' -> 'changed' to work better with the connection
			editor.  Plugin UI widgets should emit 'changed' whenever their
			UI values change in a meaningful way.
		- (nm_vpn_plugin_ui_widget_interface_update_connection): the
			update_connection member now returns validity of the UI widget



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3761 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-20 19:46:46 +00:00
Tambet Ingo 2046ec13e3 2008-06-20 Tambet Ingo <tambet@gmail.com>
* libnm-util/nm-connection.c (nm_connection_duplicate): Implement.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3759 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-20 11:26:50 +00:00
Dan Williams a9fe7c42ed 2008-06-17 Dan Williams <dcbw@redhat.com>
* libnm-glib/nm-vpn-plugin-ui-interface.c
	  libnm-glib/nm-vpn-plugin-ui-interface.h
		- Add "desc" property for longer descriptions of the VPN plugin



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3756 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-17 10:43:33 +00:00
Dan Williams 7c802e167c 2008-06-16 Dan Williams <dcbw@redhat.com>
* configure.in
	  libnm-glib/libnm_glib_vpn.pc.in
		- add a .pc file for libnm_glib_vpn

	* libnm-glib/nm-vpn-plugin-ui-interface.c
	  libnm-glib/nm-vpn-plugin-ui-interface.h
		- Move the glib/GNOME VPN UI plugin interface into libnm-glib and
			rework it substantially



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3755 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-16 19:26:30 +00:00
Dan Williams 05e9de9402 2008-06-12 Dan Williams <dcbw@redhat.com>
Add a GError argument to nm_connection_verify() and nm_setting_verify(),
	and add error enums to each NMSetting subclass.  Each NMSetting subclass now
	returns a descriptive GError when verification fails.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3751 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-12 23:58:08 +00:00
Dan Williams 99ef193601 2008-06-11 Dan Williams <dcbw@redhat.com>
Patch from Tambet Ingo <tambet@gmail.com>

	* libnm-util/nm-setting-gsm.c
		- (verify): validate APN

	* src/nm-gsm-device.c
		- (manual_registration_done): start setting APN if needed
		- (set_apn, set_apn_done): set the APN
		- (do_dial): use the APN when dialing



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3750 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-11 18:08:35 +00:00
Dan Williams a172ccdd63 2008-06-11 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerSystem.c
		- (nm_system_device_set_ip4_route,
		   nm_system_device_replace_default_ip4_route): check for the right
			return value from rtnl_route_add() to know when to add a gateway
			route (from Tambet)



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3749 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-11 18:04:43 +00:00
Dan Williams c2ffdc1d2e 2008-06-11 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerPolicy.c
		- do_ipt_cmd -> do_cmd
		- (sharing_init): use do_cmd() instead of system()



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3747 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-11 13:30:53 +00:00
Dan Williams 0fdb07ca3d 2008-06-10 Dan Williams <dcbw@redhat.com>
The grand 802-11-wireless rename.  Get rid of the 802-11/80211/802_11 bits
	and use "wifi" everwhere instead.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3742 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 16:32:39 +00:00
Dan Williams 2b00116361 2008-06-10 Dan Williams <dcbw@redhat.com>
The grand 802-3-ethernet rename.  Get rid of the 802-3/8023/802_3 bits.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3741 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 15:54:23 +00:00
Dan Williams 6919b29f11 2008-06-10 Dan Williams <dcbw@redhat.com>
Patch from Tambet Ingo <tambet@gmail.com>

	* src/ppp-manager/nm-ppp-manager.c: Add ppp stats monitoring, signal the
		changes.

	* src/nm-serial-device.c: Monitor "ppp-stats" signals from NMPPPManager. Add
		a signal to emit these changes over dbus.

	* src/Makefile.am: Genereate nm-serial-device-glue.

	* libnm-glib/nm-serial-device.[ch]: Implement.

	* libnm-glib/nm-cdma-device.[ch]
	  libnm-glib/nm-gsm-device.[ch]: Inherit from NMSerialDevice.

	* libnm-glib/Makefile.am: Add nm-serial-device.[ch].

	* introspection/nm-device-serial.xml: Implement.

	* introspection/all.xml: Fix a couple of typos, add nm-device-serial.xml.

	* introspection/Makefile.am: Add nm-device-serial.xml.

	* include/NetworkManager.h: Add a DBus interface for serial device.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3740 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 14:59:22 +00:00
Dan Williams 976326a43d 2008-06-10 Dan Williams <dcbw@redhat.com>
* configure.in
		- Add TARGET_* define to config.h to distinguish distros

	* src/dhcp-manager/nm-dhcp-manager.c
		- (dhclient_run): use distro-specific path for dhclient config file



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3739 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 12:59:32 +00:00
Dan Williams fb468f7b62 2008-06-09 Dan Williams <dcbw@redhat.com>
* src/dnsmasq-manager/nm-dnsmasq-manager.c
	  src/dnsmasq-manager/nm-dnsmasq-manager.h
		- (create_dm_cmd_line): use the IP4 address of the ip4-config to
			calculate the addresses passed to dnsmasq instead of hard-coding
			them

	* src/nm-device.c
		- (nm_device_new_ip4_shared_config): be somewhat dynamic when choosing
			IP addresses for shared connections to guard against shared
			connection address collisions
		- (real_act_stage4_get_ip4_config): handle possible NULL ip4-configs on
			error conditions
		- (nm_device_activate_stage5_ip_config_commit): pass ip4-config to
			the dnsmasq manager



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3738 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 02:52:33 +00:00
Dan Williams da3296b0ec 2008-06-09 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerPolicy.c
		- (update_routing_and_dns): set the default connection _after_ unsetting
			default on all non-default connections so that two connections can
			never be default at the same time
		- (device_state_changed): start and stop connection sharing when
			needed
		- (active_connection_default_changed): restart or stop sharing when
			the default connection changes to keep shared connections always
			NAT-ed through the default connection
		- (check_sharing): handle activation/deactivation of shared connections
		- (sharing_restart): atom-bomb approach to connection sharing until we
			can use libnl; reinit all sharing when the default connection or
			shared connections change
		- (sharing_init, sharing_stop): evil functions that init and deinit
			iptables



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3737 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 02:06:42 +00:00
Dan Williams ac64d14e8d 2008-06-09 Dan Williams <dcbw@redhat.com>
* src/nm-activation-request.c
	  src/nm-activation-request.h
		- (nm_act_request_set_shared, nm_act_request_get_shared,
		   nm_act_request_get_device): new functions to facilitate connection
			sharing



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3736 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 02:02:21 +00:00
Dan Williams 8203ac2273 2008-06-09 Dan Williams <dcbw@redhat.com>
* src/nm-device.c
		- (clear_act_request): unset the 'default' property of the activation
			request when clearing it to ensure the property changed signal gets
			delivered and handled



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3735 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 02:01:13 +00:00
Dan Williams 73946def0e 2008-06-09 Dan Williams <dcbw@redhat.com>
* libnm-glib/nm-device-802-11-wireless.c
		- (access_point_removed_proxy): actually unref the AP after removing
			it from the device's AP list.  Fixes refcounting bug for APs that
			caused them to get mixed up in the applet's menu.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3734 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-10 01:56:14 +00:00
Tambet Ingo 5827f3aa2a 2008-06-09 Tambet Ingo <tambet@gmail.com>
* src/dhcp-manager/nm-dhcp-manager.c (finalize): Free private members.
	(nm_dhcp_device_destroy): Destroy the device options hash table.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3733 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-09 08:19:09 +00:00
Dan Williams a7f2b61cdf 2008-06-06 Dan Williams <dcbw@redhat.com>
* system-settings/src/nm-polkit-helpers.c
		- (create_polkit_context): in PolicyKit 0.6, polkit_context_init() will
			unref the context if the initialization fails; also avoid spew when
			the error isn't set



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3731 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-06 19:28:53 +00:00
Dan Williams 7b1882b583 2008-06-06 Dan Williams <dcbw@redhat.com>
Patch from Tambet Ingo  <tambet@gmail.com>

	* src/NetworkManagerSystem.c
	  src/NetworkManagerSystem.h
		- (nm_system_device_add_ip4_route_via_device_with_iface): remove
		- (nm_system_device_set_from_ip4_config): remove unused route_to_iface
		- (nm_system_device_set_ip4_route): clean up
		- (nm_system_vpn_device_set_from_ip4_config): clean up, add VPN routes

	* src/nm-device.c
		- (nm_device_set_ip4_config): remove unused route_to_iface bits

	* src/vpn-manager/nm-vpn-connection.c
		- (ip_address_to_string): new function
		- (print_vpn_config): use ip_address_to_string
		- (merge_vpn_routes): add user-defined routes to the ip4 config
		- (nm_vpn_connection_ip4_config_get): add routes the VPN server sent

	* include/NetworkManagerVPN.h
		- Add 'routes' key



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3728 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-06 15:35:45 +00:00
Dan Williams ee59cd2df8 2008-06-05 Dan Williams <dcbw@redhat.com>
Patch from Markus Becker <mab@comnets.uni-bremen.de>

	* test/nm-tool.c
		- Show which device is the default device



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3723 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-06 03:31:58 +00:00
Tambet Ingo d95e330f96 2008-06-05 Tambet Ingo <tambet@gmail.com>
Fix memory leaks.

	* system-settings/src/nm-system-config-hal-manager.c (get_type_for_udi):
	Free data returned from dbus method call.

	* system-settings/src/nm-polkit-helpers.c (check_polkit_privileges):
	dbus_g_method_get_sender() returns a duplicated string, free it
	when done.
	(check_polkit_privileges): Looks like policykit sometimes returns
	error and non-null return value, don't leak errors in that case.

	* system-settings/src/main.c (find_plugin): Don't leak existing
	plugin names.
	(load_stuff): Don't leak device list and list items.
	(have_connection_for_device): Don't leak connection list.

	* system-settings/plugins/keyfile/reader.c (read_one_setting_value):
	Free the data received from g_keyfile_get_*.

	* system-settings/plugins/ifcfg-suse/parser.c (READ_WEP_KEY): Free
	the key when the security object is updated.

	* src/supplicant-manager/nm-supplicant-interface.c (scan_results_cb):
	Free data returned from dbus method call.
	(iface_state_cb): Ditto.
	(add_network_cb): Ditto.
	(nm_supplicant_interface_add_cb): Don't make another copy of already
	duplicated object path.
	(nm_supplicant_interface_add_to_supplicant): Free the driver GValue
	when done.

	* src/supplicant-manager/nm-supplicant-config.c
	(ADD_STRING_LIST_VAL): Fix a memory leak.

	* src/nm-manager.c (free_get_settings_info): Free the allocated
	memory slice.
	(list_connections_cb): Free data returned from dbus method call.
	(system_settings_get_unmanaged_devices_cb): Ditto.

	* src/nm-device-802-11-wireless.c (device_cleanup): Free ssid.

	* system-settings/plugins/ifcfg-suse/shvar.c (svCloseFile):
	* system-settings/plugins/ifcfg-fedora/shvar.c (svCloseFile):
	* src/backends/shvar.c (svCloseFile): Free the duplicated content
	of the GList.

	* libnm-util/nm-setting.c (nm_setting_from_hash): Free the constructor
	arguments after the object is created.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3721 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-05 13:16:02 +00:00
Dan Williams 4670ca1275 2008-06-04 Dan Williams <dcbw@redhat.com>
* libnm-util/Makefile.am
		- Don't distribute nm-param-spec-specialized.h



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3719 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-04 21:02:09 +00:00
Tambet Ingo 4874f758d8 2008-06-02 Tambet Ingo <tambet@gmail.com>
* libnm-util/nm-setting-ip4-config.[ch]: Add static routes property.

	* src/nm-ip4-config.[ch]: Store the static routes as a list of
	NMIP4Address, update the getters and setters.

	* src/dhcp-manager/nm-dhcp-manager.c (nm_dhcp_manager_get_ip4_config):
	Use the updated NMIP4Config routes api.

	* src/NetworkManagerUtils.c (nm_utils_merge_ip4_config): Merge
	static routes as well.

	* src/NetworkManagerSystem.c (netmask_to_prefix): Implement.
	(nm_system_device_set_from_ip4_config): Use the updated NMIP4Config
	routes api.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3715 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-06-02 08:44:48 +00:00
Dan Williams a53ebdbd37 2008-05-30 Dan Williams <dcbw@redhat.com>
* src/named-manager/nm-named-manager.c
	  src/named-manager/nm-named-manager.h
		- Remove stale/obsolete bits for controlling bind over DBus



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3714 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-05-30 18:41:30 +00:00
Dan Williams 884a070f18 2008-05-29 Dan Williams <dcbw@redhat.com>
* src/dnsmasq-manager/nm-dnsmasq-manager.c
	  src/dnsmasq-manager/nm-dnsmasq-manager.h
		- (nm_dnsmasq_manager_new): move iface argument here
		- (constructor): remove, not needed
		- (get_pidfile_for_iface, create_dm_cmd_line, kill_existing_for_iface,
		   nm_dnsmasq_manager_start, nm_dnsmasq_manager_stop): use priv->pidfile

	* src/nm-device.c
		- (real_act_stage4_get_ip4_config,
		   nm_device_activate_stage5_ip_config_commit): fix for dnsmasq manager
			changes



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3712 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-05-29 21:16:51 +00:00
Dan Williams 0aae98f986 2008-05-29 Dan Williams <dcbw@redhat.com>
* src/nm-device.c
		- (dnsmasq_state_changed_cb): new function; fail the connection if
			something happens to dnsmasq
		- (nm_device_new_ip4_shared_config): new function; create a new
			ip4-config for shared connections.  Shared connections always use a
			fixed static IP address.
		- (real_act_stage4_get_ip4_config): handle shared connections; fix
			autoip connections by actually using the returned ip4-config and
			not leaking it
		- (nm_device_activate_stage5_ip_config_commit): start dnsmasq for shared
			connections
		- (nm_device_deactivate_quickly, nm_device_dispose): terminate dnsmasq
			if its active



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3711 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-05-29 20:58:52 +00:00
Dan Williams d1f092b539 2008-05-29 Dan Williams <dcbw@redhat.com>
* src/nm-device-802-11-wireless.c
		- (real_get_best_auto_connection): auto-activate 'shared' method
			connections too



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3710 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-05-29 20:55:05 +00:00
Dan Williams cab22d895c 2008-05-29 Dan Williams <dcbw@redhat.com>
* libnm-util/nm-setting-ip4-config.c
	  libnm-util/nm-setting-ip4-config.h
		- Add a 'shared' method to indicate that this connection should be
			brought up with a DHCP and proxy DNS server to facilitate
			connection sharing.
		- (verify): 'shared' method doesn't allow DNS or searches either



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3709 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-05-29 20:53:01 +00:00
Dan Williams f20d3695ff 2008-05-29 Dan Williams <dcbw@redhat.com>
* configure.in
	  src/Makefile.am
	  src/dnsmasq-manager/Makefile.am
	  src/dnsmasq-manager/nm-dnsmasq-manager.c
	  src/dnsmasq-manager/nm-dnsmasq-manager.h
		- Add a dnsmasq daemon manager to facilitate connection sharing



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3708 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2008-05-29 20:47:10 +00:00