Commit graph

334 commits

Author SHA1 Message Date
Dan Williams fc8130ddd0 2007-10-03 Dan Williams <dcbw@redhat.com>
* src/nm-device-802-11-wireless.c
	  src/nm-device-802-11-wireless.h
	  introspection/nm-device-802-11-wireless.xml
		- GetActiveNetworks -> GetAccessPoints
		- ActiveNetwork -> ActiveAccessPoint
		- NetworkAdded -> AccessPointAdded
		- NetowrkRemoved -> AccessPointRemoved

	* libnm-glib/nm-device-802-11-wireless.c
	  libnm-glib/nm-device-802-11-wireless.h
		- network-added signal -> access-point-added
		- network-removed signal -> access-point-removed
		- nm_device_802_11_wireless_get_active_network() ->
			nm_device_802_11_wireless_get_active_access_point()
		- nm_device_802_11_wireless_get_network_by_path() ->
			nm_device_802_11_wireless_get_access_point_by_path()
		- nm_device_802_11_wireless_get_networks() ->
			nm_device_802_11_wireless_get_access_points()

	* libnm-glib/libnm-glib-test.c
	  test/nm-tool.c
	  src/NetworkManagerPolicy.c
		- Fixups for Network -> AccessPoint



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2928 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-03 18:20:35 +00:00
Dan Williams f9fd8667d1 2007-10-03 Dan Williams <dcbw@redhat.com>
Add a GetActiveConnections() method on the Manager object.

	* src/nm-manager.c
	  src/nm-manager.h
	  introspection/nm-manager.xml
		- (connection_get_settings_cb): keep connection type around too
		- (impl_manager_get_active_connections, add_one_connection_element):
			implement; returns all active connections and what devices they
			apply to

	* libnm-glib/nm-client.c
	  libnm-glib/nm-client.h
	  introspection/nm-manager-client.xml
		- (nm_client_get_devices): GPtrArray elements are allocated and owned
			by the caller; free here to avoid memory leak
		- (nm_client_get_active_connections): implement; return the list of
			active connections
		- (nm_client_free_active_connection_element): implement; free an element
			of the GSList returned by nm_client_get_active_connections()



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2927 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-03 14:48:25 +00:00
Dan Williams e5b834c1f9 2007-10-01 Dan Williams <dcbw@redhat.com>
* include/NetworkManagerVPN.h
		- define VPN connection state change reason codes

	* src/vpn-manager/Makefile.am
	  src/vpn-manager/nm-vpn-marshal.list
	  src/vpn-manager/nm-vpn-marshal-main.c
		- Add marshallers for StateChanged signal

	* introspection/nm-vpn-connection.xml
		- New Banner property
		- StateChanged signal now includes a 'reason' argument

	* src/vpn-manager/nm-vpn-connection.c
	  src/vpn-manager/nm-vpn-connection.h
		- Add a "Banner" property that contains the returned VPN server login
			banner (if any); valid only in the ACTIVATED state
		- (nm_vpn_connection_set_state, nm_vpn_connection_disconnect): now takes
			a 'reason' argument and emits that reason along with the
			state-changed signal
		- Fix up calls to nm_vpn_connection_set_state() to include a reason
		- (nm_vpn_connection_ip4_config_get): save banner for later
		- (nm_vpn_connection_get_banner, get_property,
		   nm_vpn_connection_class_init): implement Banner property

	* src/vpn-manager/nm-vpn-service.c
		- (nm_vpn_service_connections_stop): take a reason argument; copy the
			connection list because elements may get added/removed from it
			while iterating over the list
		- (connection_state_changed): signal now includes the 'reason' argument

	* libnm-glib/nm-vpn-connection.c
	  libnm-glib/nm-vpn-connection.h
		- (nm_vpn_connection_get_banner): new function
		- (state_changed_proxy): handle reason argument



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2916 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-01 17:57:36 +00:00
Tambet Ingo 485bcfe571 2007-09-28 Tambet Ingo <tambet@gmail.com>
* src/nm-manager.c:
        * src/nm-manager.h:
        Implement device activation through NMManager.
        Implement "pending device activation" here - If the connection
isn't found,
        we try to wait for up to 5 seconds for the connection to be
provided.
        Add NMConnectionType argument to "connection-added" and
"connection-removed"
        signals.
        (nm_manager_get): Remove. Finally.

        * src/nm-activation-request.c: 
        * src/nm-activation-request.h: 
        Remove all the deferred activation code.

        * src/nm-device.c: Remove all the deferred activation code. Once
        * the device
        activation is started, it's started. Update the activation
virtual function
        signature.

        * src/nm-device-interface.c:
        * src/nm-device-interface.h:
        Device activation now takes only NMActRequest argument.
        Don't expose device activation directly on dbus, it's supposed
to go through
        NMManager now.

        * src/NetworkManagerPolicy.c (nm_policy_device_change_check):
        * Make the code
        a bit more compact.
        Use the new device activation methods through NMManager.

        * introspection/nm-manager-client.xml: 
        * introspection/nm-manager.xml: 
        * libnm-glib/nm-client.c:
        * libnm-glib/nm-client.h:
        Add device activation method.
        
        * libnm-glib/nm-device.c: 
        * libnm-glib/nm-device.h: 
        * introspection/nm-device.xml: 
        Remove device activation method. It's done through NMManager
now.

        * src/vpn-manager/nm-vpn-manager.c (impl_vpn_manager_connect):
        * Use the shiny
        new (nm_manager_get_device_by_path) function, get rid of our own
)find_device).



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2915 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-10-01 15:38:39 +00:00
Dan Williams d7696ae510 2007-09-26 Dan Williams <dcbw@redhat.com>
* introspection/nm-vpn-plugin.xml
	  libnm-glib/nm-vpn-plugin.c
	  libnm-glib/nm-vpn-plugin.h
		- (impl_vpn_plugin_need_secrets): implement a call that should return
			the name of the NMSetting in an NMConnection that may require
			secrets specific to that VPN plugin



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2892 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-27 02:20:53 +00:00
Tambet Ingo 571812b40c 2007-09-26 Tambet Ingo <tambet@gmail.com>
* libnm-glib/nm-vpn-plugin.c (nm_vpn_plugin_connect): Update the
        * plugin activation
        method.
        (impl_vpn_plugin_connect): Convert properties hash to
NMConnection, activate, and
        unreference the connection.

        * introspection/nm-vpn-plugin.xml: Modify the 'Connect' method
        * arguments: instead of
        passing properties hash and routes string list, pass
NMConnection (in hashed form).

        * src/vpn-manager/nm-vpn-connection.c
        * (nm_vpn_connection_get_routes): Return routes
        as GSList, no need to copy stuff around anymore.
        (nm_vpn_connection_activate): Update the plugin activation
method.

        * src/NetworkManagerSystem.c
        * (nm_system_vpn_device_set_from_ip4_config): Convert
        routes argument to GSList.

        * vpn-daemons/vpnc/src/nm-vpnc-service.c (real_connect):
        The arguments have changed, update.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2890 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-26 15:42:09 +00:00
Dan Williams 04f8d563fa 2007-09-25 Dan Williams <dcbw@redhat.com>
* introspection/nm-device.xml
	  libnm-glib/nm-device.c
	  libnm-glib/nm-device.h
		- Add 'Carrier' property to exported NMDevice objects

	* src/nm-device-interface.h
	  src/nm-device-interface.c
	  src/nm-device.c
		- Add a 'carrier' property to internal NMDevice objects



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2884 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-25 17:30:01 +00:00
Dan Williams 1817c62082 2007-09-25 Dan Williams <dcbw@redhat.com>
Properly re-query secrets from the settings daemon when stuff fails.

	* src/nm-device-802-11-wireless.c
		- (ap_auth_enforced): handle static WEP correctly here by differentiating
			between Shared Key and Open System auth modes
		- (link_timeout_cb, supplicant_connection_timeout_cb,
		   real_act_stage4_ip_config_timeout): clear existing secrets and
			request new ones when something fails due to a suspected wrong key
		- (real_act_stage2_config): fix for new request_new argument to
			nm_manager_get_connection_secrets()

	* src/nm-manager.c
	  src/nm-manager.h
		- (nm_manager_get_connection_secrets): return error status; pass
			new request_new argument on to the settings daemon

	* introspection/nm-settings-connection.xml
		- New 'request_new' argument to the GetSecrets call that hints to the
			settings daemon to ask the user for completely new secrets

	* libnm-glib/nm-settings.c
	  libnm-glib/nm-settings.h
		- (impl_connection_settings_get_secrets): handle new 'request_new'
			argument



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2872 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-25 06:21:38 +00:00
Dan Williams 9496e413c7 2007-09-24 Dan Williams <dcbw@redhat.com>
* introspection/nm-manager.xml
	  src/nm-manager.c
		- (impl_manager_legacy_state): fix 'state' method call return value



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2865 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-24 21:26:56 +00:00
Dan Williams 73792d12eb Fix distcheck
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2831 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-20 11:37:14 +00:00
Dan Williams 174d339a34 2007-09-20 Dan Williams <dcbw@redhat.com>
* introspection/nm-settings-connection.xml
	  libnm-glib/nm-settings.c
	  libnm-glib/nm-settings.h
		- Make GetSecrets asynchronous on the server side



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2829 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-20 09:22:42 +00:00
Tambet Ingo 6746319495 2007-09-20 Tambet Ingo <tambet@gmail.com>
* libnm-util/nm-connection.c (register_default_creators): Use
        * defined
        setting names. Register NMSettingVPN and NMSettingVPNProperties.

        * libnm-util/nm-setting.c: Define property name strings, use
        * them.
        Implement NMSettingVPN and NMSettingVPNProperties settings.
        Implement NM_S_TYPE_GVALUE_HASH.
        (nm_setting_populate_from_hash): Handle NM_S_TYPE_GVALUE_HASH.
        (setting_connection_verify): Rename 'devtype' property to
'type'.

        * introspection/nm-vpn-manager.xml: Use NMConnection for VPN
        * service
        properties.

        * src/vpn-manager/nm-vpn-service.c: Ditto.

        * src/vpn-manager/nm-vpn-connection.c: Ditto.

        * src/vpn-manager/nm-vpn-manager.c (nm_vpn_manager_connect):
        * Ditto.
        (nm_vpn_manager_new): Remove NMManager argument, it's easy
enough to get.

        * src/nm-device-802-11-wireless.c (find_best_connection): Use
        * defined setting
        names. NMSettingConnection->devtype got renamed to 'type'.

        * src/nm-device-802-3-ethernet.c (find_best_connection):
        (real_get_best_connection): Ditto.

        * src/NetworkManager.c (main): Update the vpn manager creation
        * arguments.

        * libnm-glib/nm-vpn-manager.[ch]: Update.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2826 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-20 06:47:15 +00:00
Dan Williams d92897393e 2007-09-19 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerAP.c
	  src/NetworkManagerAP.h
	  introspection/nm-access-point.xml
		- Change strength-changed signal into a properties-changed signal
			for all properties, not just strength.  Export that signal over dbus
			so listeners don't have to poll NM for changes.
		- (nm_ap_export_to_dbus, nm_ap_new): not every NMAccessPoint should
			get exported over D-Bus, so break up the logic and let other bits
			decided when to export the AP
		- (nm_ap_new_from_ap): remove, unused

	* src/nm-device-802-11-wireless.c
		- (merge_scanned_ap): only export APs that are actually on the device
			list, not every AP created internally

	* libnm-glib/nm-access-point.c
	  libnm-glib/nm-access-point.h
		- Cache properties internally and only hit DBus when needed.  Get
			property updates from NM signals



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2825 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-19 20:44:37 +00:00
Tambet Ingo 326d1e8679 2007-09-12 Tambet Ingo <tambet@gmail.com>
* src/vpn-manager/nm-vpn-connection.[ch]: 
        * src/vpn-manager/nm-vpn-manager.[ch]:
        * src/vpn-manager/nm-vpn-service.[ch]: Rewrite the vpn handling
        * code. Using 
        dbus-glib, GObjects, signals etc.

        * libnm-glib/nm-vpn-manager.[ch]: 
        * libnm-glib/nm-vpn-connection.[ch]: Now that the NM
        * implementation changed
        so much, rewrite these too.

        * libnm-glib/Makefile.am: Add new files to build, build new
        * binding files for
        the new introspection files.

        * libnm-glib/nm-client.[ch]: Remove all VPN related stuff from
        * here.

        * libnm-glib/nm-dbus-utils.[ch]: Renamed from nm-utils.[ch] that
        * was shadowing
        the header with the same name from libnm-utils.

        * libnm-glib/nm-vpn-plugin.[ch]: Implement.

        * libnm-util/Makefile.am: Add nm-utils.[ch] to build.

        * introspection/nm-vpn-plugin.xml: Implement.

        * introspection/nm-vpn-connection.xml: Implement.

        * introspection/nm-vpn-manager.xml: Implement.

        * src/NetworkManagerSystem.c
        * (nm_system_vpn_device_set_from_ip4_config): Remove
        the named manager argument, it can just as easily get it as the
caller.
        (nm_system_vpn_device_unset_from_ip4_config): Ditto.

        * src/vpn-manager/nm-dbus-vpn.[ch]: Remove.

        * src/nm-dbus-manager.h: Fix up the name_owner signal signature.

        * src/dhcp-manager/nm-dhcp-manager.c (garray_to_string): Remove,
        * use one from
        libnm-utils.

        * libnm-util/nm-connection.c: Ditto.

        * src/NetworkManagerMain.h: Remove, it's finally empty.

        * configure.in: Remove utils/ from build.

        * include/NetworkManagerVPN.h: Add some more defines to reduce
        * the amount
        of hard-coded strings.

        * utils/: Move it over to libnm-util.

        * test/Makefile.am: Link against libnm-util now that util/ is
        * gone.

        * dispatcher-daemon/Makefile.am: Ditto.

        * src/Makefile.am: Ditto.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2798 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-12 16:23:53 +00:00
Dan Williams ab4aa2d752 2007-09-11 Dan Williams <dcbw@redhat.com>
* introspection/nm-device.xml
	  libnm-glib/nm-device.c
	  libnm-glib/nm-device.c
		- Fix Activate call argument borkage; Activate takes 3 arguments



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2789 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-11 19:33:29 +00:00
Dan Williams 8b905b9762 2007-09-10 Dan Williams <dcbw@redhat.com>
* src/NetworkManagerAP.c
	  src/NetworkManagerAP.h
	  introspection/nm-access-point.xml
		- Change 'freq' property to a guint32 instead of a double since we
			weren't using the floating point bits anyway



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2780 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-10 19:56:31 +00:00
Dan Williams fba106c5b0 2007-09-09 Dan Williams <dcbw@redhat.com>
* introspection/nm-device.xml
		- The 'Activate' method now takes 3 arguments, a service name for the
		settings service (user or system), the object path of the connection
		to activate, and the specific object to activate, if any

	* src/nm-device-interface.c
		- (nm_device_interface_error_quark, nm_device_interface_error_get_type):
		Add error bits
		- (impl_device_activate): adapt to new Activate arguments; validate
		the service name and get the Connection object from the NMManager
		before starting to activate the device with the specified connection

	* src/nm-device-802-3-ethernet.c
		- (real_get_best_connection): find the best connection, or create a
		default one if no existing connections can be used

	* src/NetworkManagerPolicy.c
		- (nm_policy_auto_get_best_device): Get the device's best connection
		and only pick the device if it has one
		- (nm_policy_device_change_check): disable wireless bits for now until
		wireless get_best_connection() can be implemented (replacing "best_ap");
		don't create a default connection here as the device subclass will do
		that if needed

	* src/nm-manager.h
	  src/nm-manager.c
		- (nm_manager_get): make NMManager a singleton and expose the getter
		internally
		- Rework internal NMManager connection handling to use the same
		routines for both the system and user settings services.  Most calls
		take a new NMConnectionType argument specifying either system or user
		connections
		- (nm_manager_get_connection_by_object_path): new function; get a
		connection keyed on its object path

	* src/NetworkManager.c
		- (main): use nm_manager_get()



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2776 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-09 22:18:42 +00:00
Dan Williams b1872d9ac2 2007-09-09 Dan Williams <dcbw@redhat.com>
Stupid mistake on my part; object path and interface for settings service
	and connection objects can be the same, only the service name must be
	different for the system and user settings services.

	* include/NetworkManager.h
	  src/nm-manager.c
	  introspection/nm-settings-connection.xml
	  introspection/nm-settings.xml
	  libnm-glib/nm-settings.c
		- (nm_connection_settings_init, query_user_connections,
		   new_connection_cb): Unify NetworkManagerSettings and Connection
		   interface name and object path



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2772 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-09 14:48:31 +00:00
Dan Williams 5dc24dd407 2007-09-06 Dan Williams <dcbw@redhat.com>
* introspection/nm-access-point.xml
		- Fix WpaFlags and RsnFlags property names to be what dbus-glib expects
			them to be.  There's some magic property name parsing going on in
			dbus-glib that breaks up property names based on studly-caps and
			puts - between words.

	* libnm-glib/nm-access-point.c
		- (nm_access_point_get_wpa_flags, nm_access_point_get_rsn_flags):
			Fix property names



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2766 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-09-06 19:15:49 +00:00
Dan Williams 8bd92323e4 2007-08-29 Dan Williams <dcbw@redhat.com>
* introspection/nm-settings-connection.xml
	  introspection/nm-settings.xml
		- Service name -> NetworkManagerUserSettings because two services
		can't share part of the same path.  I'm not really sure how we'll use
		the same code with the system-settings daemon...



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2744 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-29 21:12:24 +00:00
Dan Williams 7a8f33aa3d 2007-08-28 Dan Williams <dcbw@redhat.com>
Remove NMAPSecurity objects, they are replaced with flags on the APs for
	each AP's capabilities, and by NMConnection/NMSettings objects for user
	defined connections.

	* include/NetworkManager.h
		- Redefine 802.11 security properties.  There are now device capabilities
			and AP flags and AP security flags.  It was way to unclear before.

	* src/Makefile.am
	  src/nm-ap-security-leap.h
	  src/nm-ap-security-leap.c
	  src/nm-ap-security-wpa-eap.c
	  src/nm-ap-security-wpa-eap.h
	  src/nm-ap-security-private.h
	  src/nm-ap-security-wpa-psk.c
	  src/nm-ap-security-wpa-psk.h
	  src/nm-ap-security-wep.c
	  src/nm-ap-security-wep.h
	  src/nm-ap-security.c
	  src/nm-ap-security.h
		- Removed, to be replaced with NMConnection/NMSettings objects

	* src/nm-dbus-nmi.c
	  src/nm-dbus-nmi.h
		- Removed, to be replaced by code that talks to the new info daemon
			interface and gets NMConnection/NMSettings objects

	* src/backends/NetworkManagerSuSE.c
		- Remove usage of NMAPSecurity; should be replaced by a system-level
			info-daemon that does the same thing but talks the new info-daemon
			D-Bus interface

	* src/NetworkManagerAP.h
	  src/NetworkManagerAP.c
	  src/NetworkManagerAPList.c
	  libnm-glib/libnm-glib-test.c
		- Remove usage of NMAPSecurity objects and adjust to new flags for
			WPA/RSN

	* libnm-glib/nm-access-point.c
	  libnm-glib/nm-access-point.h
	  introspection/nm-access-point.xml
	  test/nm-tool.c
		- Adjust to new flags for AP security

	* utils/nm-utils.c
	  utils/nm-utils.h
	  src/vpn-manager/nm-dbus-vpn.c
		- Remove D-Bus pending call stuff from nm-utils and put it in the VPN
			stuff which is the only place it's used

	* src/nm-device-interface.c
	  src/nm-device-interface.h
	  introspection/nm-device.xml
	  src/nm-activation-request.c
	  src/nm-activation-request.h
	  src/nm-device.c
		- Add a new 'specific_object' argument that hints to NM what actual
			AP or other device-specific thing the connection should apply to.
			NMConnection objects can apply to more than one actual device/AP.

	* libnm-util/nm-connection.c
	* libnm-util/nm-connection.h
		- Add 'have_secrets" call stubs

	* libnm-util/cipher.h
		- Move NM_AUTH_TYPE_* defines here for now

	* src/nm-device-802-11-wireless.c
		- Remove usage of NMAPSecurity, to be replaced with NMConnection/
			NMSettings objects

	* src/NetworkManagerDbus.c
	* src/NetworkManagerPolicy.c
		- Remove usage of update_allowed_networks, should be pushing data in
			a different manner



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2738 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-28 14:47:31 +00:00
Dan Williams 2b768e222a 2007-08-26 Dan Williams <dcbw@redhat.com>
* introspection/nm-device.xml
		- Add 'Index' property on NMDevice objects (forgot to do this earlier)



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2734 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-26 18:53:15 +00:00
Tambet Ingo eaf775ea30 2007-08-15 Tambet Ingo <tambet@gmail.com>
* introspection/Makefile.am: Add nm-manager-client.xml to
        * EXTRA_DIST.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2689 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-15 08:15:58 +00:00
Tambet Ingo 8bed6ff2de 2007-08-14 Tambet Ingo <tambet@gmail.com>
* libnm-glib/Makefile.am: Use nm-manager-client.xml to produce
        * nm-client-bindings.

        * introspection/nm-manager-client.xml: Add a horrible horrbile
        * hack to work around
        an issue with dbus-glib bindings generator. The issue is, the
generated C caller
        functions for dbus methods "Sleep(bool)" and "sleep()" both have
the same function
        name and different arguments and it won't compile anymore. To
fix this, we now have
        two copies of nm-manager.xml file. nm-manager.xml contains the
actual interface,
        that is new API + compatibility API and used by the daemon. The
other, 
        nm-manager-client.xml is only the new API without compatibility
bits and is used
        by libnm-glib to make it compile.

        * introspection/nm-manager.xml: Define compatibility methods
        * (sleep, wake, state).

        * src/nm-manager.c (impl_manager_legacy_sleep)
        (impl_manager_legacy_wake, impl_manager_legacy_state): Implement
the compatibility
        interface functions for 0.6 branch.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2688 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-15 07:52:25 +00:00
Tambet Ingo 6a68d79c08 2007-08-09 Tambet Ingo <tambet@gmail.com>
[Based on patch by Helmut Schaa <hschaa@suse.de>]

        * libnm-glib/nm-client.h:
        * libnm-glib/nm-object.h:
        * libnm-glib/nm-vpn-connection.h:
        * libnm-glib/nm-settings.h:
        * libnm-glib/nm-device.h:
        * libnm-glib/nm-ip4-config.h:
        * libnm-glib/nm-access-point.h:
        * libnm-glib/nm-device-802-3-ethernet.h:
        * libnm-util/nm-setting.h: 
        * libnm-util/nm-connection.h: Add G_BEGIN_DECLS / G_END_DECLS to
        * support C++.

        * libnm-glib/nm-object.c (nm_object_get_byte_property):
        * Implement.

        * libnm-glib/nm-access-point.c: Strength has type char.

        * gnome/vpn-properties/Makefile.am: Remove
        * GNOME_DISABLE_DEPRECTATED for now
        to fix build. GnomeDruid is deprecated in recent libgnomeui.

        * introspection/nm-access-point.xml: Strength property is char,
        * not int.

        * src/NetworkManagerAP.c (set_property): Set strength from char.
        (get_property): Handle hidden APs (with empty SSID).
        Get strength value from char.
        (nm_ap_class_init): Strength property has char type.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2659 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-09 09:19:57 +00:00
Rodrigo Moya 8fa04018cc 2007-08-03 Rodrigo Moya <rodrigo@gnome-db.org>
* introspection/Makefile.am:
	* introspection/nm-settings.xml:
	* introspection/nm-settings-connection.xml: added Settings interfaces.

	* libnm-glib/nm-settings.[ch]:
	* libnm-glib/Makefile.am: added abstract class for Settings interfaces
	containing the DBus implementation.

git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2656 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-08-03 16:10:04 +00:00
Christopher Aillon aa9a2cbb6a 2007-07-10 Christopher Aillon <caillon@redhat.com>
Patch from Robert Buchholz <rbu@gentoo.org>:

	* configure.in:
	* Makefile.am:
	* introspection/Makefile.am:
	Make make distcheck work again.


git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2628 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-07-10 18:31:32 +00:00
Dan Williams f4540f0412 2007-06-27 Dan Williams <dcbw@redhat.com>
* Make SSIDs GByteArrays everywhere
	* Rename "essid" -> "ssid" everywhere that's appropriate
	* Refcount activation_ap member of the 802.11 wireless device class



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2620 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-06-27 16:18:52 +00:00
Tambet Ingo ff0fd77b08 2007-05-07 Tambet Ingo <tambet@ximian.com>
* libnm-glib/Makefile.am: Link with libnm-util to gain access to
	NMConnection.

	* libnm-glib/nm-device-802-11-wireless.c:
	(nm_device_802_3_ethernet_activate): Remove.

	* libnm-glib/nm-device-802-3-ethernet.c
	(nm_device_802_3_ethernet_activate): Remove.

	* libnm-glib/nm-device.c (nm_device_activate): Implement.

	* src/nm-device-802-3-ethernet.c: Implement the new activation using
	NMConnection.

	* src/nm-device-802-11-wireless.c: Store an activation AP once the
	activation has started.
	Implement the new activation using NMConnection.

	* src/nm-activation-request.c: Store a generic connection object instead
	of a wireless-specific AP.

	* src/NetworkManagerPolicy.c (create_connection): Implement. Depending
	on device type, create a device specific connection object suitable for
	device activation.

	* src/nm-device.c (nm_device_activate): Re-implement. Call the device
	specific check to validate the connection and on success start the
	activation.

	* src/nm-device-interface.h: Add a activate virtual function to the
	interface definition.

	* src/nm-device-interface.c (nm_device_interface_activate): Implement.
	(impl_device_activate): Implement.

	* introspection/nm-device.xml: Add a generic device activation interface
	that accepts an abstract NMConnection structure that has device-specific
	information in it.

	* introspection/nm-device-802-3-ethernet.xml: Remove the wired-specific
	activation interface.

	* introspection/nm-device-802-11-wireless.xml: Remove the wireless-specific
	activation interface.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2569 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-05-07 15:17:45 +00:00
Tambet Ingo 96c246cfc4 2007-03-02 Tambet Ingo <tambet@ximian.com>
* libnm-glib/nm-device-802-11-wireless.c
	(nm_device_802_11_wireless_get_capabilities): Implement.

	* libnm-glib/nm-device.c (nm_device_get_capabilities): Implement.

	* src/nm-device-802-11-wireless.c: Add "WirelessCapabilities" property.

	* src/named-manager/nm-named-manager.c (remove_one_zone_from_named): Unref the
	reply only if it's not NULL. Not sure why this started happening right now.

	* src/nm-manager.c (device_stop_and_free): Remove. No need to have different
	code paths for when devices get removed on shutdown or when a device is just
	removed.
	(finalize): Don't use a g_slist_foreach() when removing devices, the list data
	gets freed so any signal from a device (disconnected for instance) would invoke
	NMState update which would crash.
	(nm_manager_remove_device): Bring the device down when it gets removed.

	* src/NetworkManagerPolicy.c (nm_policy_auto_get_best_device): Remove
	the unused dev_type.

	* src/nm-hal-manager.c (create_device_and_add_to_list): Don't keep the
	reference to the added device, NMManager will own it (if it wants).

	* test/nm-tool.c: Rewrite using libnm-glib.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2417 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-03-05 08:49:30 +00:00
Tambet Ingo 3dcd9d2d17 2007-02-19 Tambet Ingo <tambet@ximian.com>
* src/vpn-manager/nm-vpn-manager.c: Handle the DBUS state changes itself.
	Handle device state changes and disconnect VPN if it's device deactivates.

	* src/nm-dbus-nm.c: 
	* src/nm-dbus-nm.h: 
	* src/nm-dbus-device.c: 
	* src/nm-dbus-device.c: 
	* src/nm-dbus-net.c: 
	* src/nm-dbus-net.h: Remove. All of it is implemented byt the new dbus API.

	* src/NetworkManagerMain.h: Get rid of all but 3 properties of NMData.

	* src/nm-device.c (nm_device_get_by_udi):
	(nm_device_get_by_iface): Remove. This doesn't belong here and is already
	implemented in the correct location (NMManager).
	Rip out all the test_device stuff.

	* src/NetworkManagerPolicy.c: Remove the leftover activation success and
	failure handlers, it's all done by NMDevice already.

	* src/NetworkManager.c: Move the signal handling here from nm-logging.c
	Remove the iochannel hack to route the unix signals to the main thread since
	we're not threaded anymore.

	* src/NetworkManagerAP.c: Implement HWAddress property.

	* src/NetworkManagerDbus.c: Remove the dbus signal sending code, it happens
	automatically with dbus-glib.

	* src/nm-netlink-monitor.c: 
	* src/nm-netlink-monitor.h:
		- Move it low in the class hierarchy, don't reference any NM types.
		- Remove private data from the header.
		- Use type safe checks in public API methods.
		- Make it a singleton so we don't have to pass the single reference around.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2339 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-02-19 13:09:32 +00:00
Tambet Ingo c40051389c 2007-02-16 Tambet Ingo <tambet@ximian.com>
* introspection/nm-ip4-config.xml: Implement.

	* libnm-glib/libnm-glib-test.c: Use new DBUS API in tests.

	* libnm-glib/nm-ip4-config.c:
	* libnm-glib/nm-ip4-config.c: Implement.

	* src/nm-ap-security[-*]: Remove circular dependencies between APs and AP
	securities. APs reference security.

	* src/nm-device-802-11-wireless.c: Implement missing properties that need to
	be exported over DBUS.

	* src/nm-device-802-3-ethernet.c: Ditto.

	* src/NetworkManagerAP.c:
	* src/NetworkManagerAP.h:
		- Convert to GObject, export over DBUS.

	* src/nm-ip4-config.h:
	* src/nm-ip4-config.h:
		- Convert to GObject, export over DBUS.




git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2322 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-02-16 11:23:49 +00:00
Tambet Ingo 7eeefaea40 2007-02-12 Tambet Ingo <tambet@ximian.com>
* libnm-glib/nm-device.c (nm_device_get_use_dhcp): Remove.

	* libnm-glib/nm-access-point.c (nm_access_point_is_broadcast): Remove.

	* introspection/nm-device-802-3-ethernet.xml: Rename 'Address' property to
	'HwAddress'.

	* introspection/nm-device.xml: Remove 'UseDhcp' property.

	* introspection/nm-access-point.xml: Remove 'Broadcast' property.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2310 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-02-12 14:46:49 +00:00
Tambet Ingo 8a4c57f631 2007-02-12 Tambet Ingo <tambet@ximian.com>
Totally break NetworkManager. Please use 0.6 branch until futher notice.

	* src/:
		- Remove old low-level dbus interface implementations and replace them
		  with dbus-glib one.

	* configure.in:
		- Require dbus-glib >= 0.72.
		- Plug in new sources to build.

	* libnm-glib/:
		- Implement GObject wrappers on top of DBUS glib auto-generated bindings
		  to make it more convenient to use from GObject based programs.

	* introspection/:
		- Implement DBUS XML introspection files, used by both NM and libnm-glib.



git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@2309 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
2007-02-12 09:23:43 +00:00