* src/nm-device.c
- (nm_device_set_ip4_config): don't touch hostnames here; distros
that want to use DHCP hostnames should use dispatcher scripts
for that
* src/NetworkManagerSystem.h
src/backends/NetworkManagerArch.c
src/backends/NetworkManagerDebian.c
src/backends/NetworkManagerFrugalware.c
src/backends/NetworkManagerGeneric.c
src/backends/NetworkManagerGeneric.h
src/backends/NetworkManagerGentoo.c
src/backends/NetworkManagerMandriva.c
src/backends/NetworkManagerPaldo.c
src/backends/NetworkManagerRedHat.c
src/backends/NetworkManagerSlackware.c
src/backends/NetworkManagerSuSE.c
- Remove nm_system_set_hostname(), no longer used
* src/backends/Makefile.am
src/backends/shvar.c
src/backends/shvar.h
- Remove shvar.*; no longer used
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3946 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Revert most of the 'hostname' patch. Too much stuff still breaks when
hostname is updated at runtime. Distros or users who want hostname updates
can use dispatcher scripts to update the hostname if they need it.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3945 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* introspection/nm-settings-system.xml
system-settings/src/dbus-settings.c
system-settings/src/dbus-settings.h
- Add a 'Hostname' property (rw) which represents the configured
hostname and domain of the system, if any
* system-settings/src/nm-system-config-error.c
system-settings/src/nm-system-config-error.h
system-settings/src/nm-system-config-interface.c
system-settings/src/nm-system-config-interface.h
- Add a 'hostname' property to the plugin interface
- Add a method to send updated hostname to plugins to save in their
backing configuration store
* system-settings/plugins/keyfile/nm-keyfile-connection.c
system-settings/plugins/keyfile/plugin.c
system-settings/plugins/keyfile/writer.c
system-settings/plugins/keyfile/writer.h
system-settings/plugins/ifcfg-suse/plugin.c
- Add minimal hostname support
* system-settings/plugins/ifcfg-fedora/plugin.c
- Add support for updating system hostname in /etc/sysconfig/network
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3941 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/plugins/ifcfg-fedora/shvar.c
system-settings/plugins/ifcfg-fedora/shvar.c
- Fix double-free caused by svSetValue() followed by svCloseFile()
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3940 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/backends/*: Get rid of nm_system_should_modify_resolv_conf().
* src/named-manager/nm-named-manager.c (rewrite_resolv_conf): Calculate
the composite result of all the IP4 configurations and call a distro
specific update_resolv_conf().
(update_resolv_conf): Implement one for directly writing to
/etc/resolv.conf and one for opensuse to call netconfig.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3931 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Merge the vpn-properties setting with the vpn setting since it was pointless
to keep both of them around. Convert the vpn 'data' hash table to a hash
of string:string (instead of string:variant) so that system settings plugins
can have an easier time dealing with the arbitrary key/value pairs.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3924 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-glib/nm-vpn-plugin.c
- (nm_vpn_plugin_connect): stop plugin after connection failure from
an idle handler so the Connect reply gets delivered before the
stop StateChanged signal
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3920 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-ip4-config.c
- (get_property): use common ip4 address/route conversion functions
- (nm_ip4_config_replace_address, nm_ip4_config_replace_route): should
copy the new route here, not take ownership
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3919 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/dhcp-manager/nm-dhcp-manager.c
- (nm_dhcp_manager_get_ip4_config): fix regression which caused
mis-handling of DHCP responses that returned more than one router
(found by Grant Williamson)
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3908 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* callouts/nm-dispatcher-action.c
- (nm_dispatcher_action): grab device path and create the device; pass
the device's DHCP4 config to script caller
- (dispatch_scripts): dump the DHCP4 config to the environment of called
scripts
* libnm-glib/nm-dhcp4-config.c
libnm-glib/nm-dhcp4-config.h
- (nm_dhcp4_config_get_options): expose
- (nm_dhcp4_config_get_one_option): renamed from nm_dhcp4_config_get_option
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3907 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* include/NetworkManager.h
- Add the DHCP4Config D-Bus interface
* libnm-glib/Makefile.am
libnm-glib/nm-dhcp4-config.c
libnm-glib/nm-dhcp4-config.h
- Handle DHCP4 config objects exported by NM over D-Bus
* libnm-glib/nm-device.c
libnm-glib/nm-device.h
- Add a 'dhcp4-config' property
* libnm-glib/libnm-glib-test.c
- Print out DHCP4 config for devices
- Fix some crashes when no connections are active
* src/nm-device-interface.c
src/nm-device.c
src/nm-dhcp4-config.c
src/nm-dhcp4-config.h
- Treat dhcp4-config object as an object path at the D-Bus interface so
that when it doesn't exist we can proxy it as "/" which dbus-glib
doesn't let us do when the property type is G_TYPE_OBJECT
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3905 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-glib/nm-ip4-config.c
libnm-glib/nm-ip4-config.h
- Add 'routes' property
* libnm-util/nm-setting-vpn.c
libnm-util/nm-setting-vpn.h
- Remove 'routes' property
* libnm-util/nm-setting-ip4-config.c
libnm-util/nm-setting-ip4-config.h
- 'ignore-dhcp-dns' renamed to 'ignore-auto-dns'
- Add 'ignore-auto-routes' property
- 'routes' exposed over D-Bus is now an array of array of uint (4) to
accomodate route metrics
- 'routes' exposed in C is now a list of NMSettingIP4Route structures
* libnm-util/nm-utils.c
libnm-util/nm-utils.h
- Add helpers for marshalling IP4 routes
* src/NetworkManagerUtils.c
- (nm_utils_merge_ip4_config): handle property renames and new route
structure
* src/NetworkManagerSystem.c
- (nm_system_device_set_ip4_route, nm_system_device_set_from_ip4_config,
nm_system_vpn_device_set_from_ip4_config): respect route metrics
* src/dhcp-manager/nm-dhcp-manager.c
- (nm_dhcp_manager_get_ip4_config): handle new route structure
* system-settings/plugins/ifcfg-fedora/reader.c
system-settings/plugins/ifcfg-fedora/writer.c
- Handle routes separately from addresses now that routes have a different
format
* introspection/nm-ip4-config.xml
src/nm-ip4-config.c
src/nm-ip4-config.h
- Rename internal routing functions
- 'static-routes' renamed to 'routes'
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3898 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Patch from Sjoerd Simons <sjoerd.simons@collabora.co.uk>
* src/NetworkManager.c
src/nm-manager.c
src/nm-manager.h
- More explicitly make the NMManager a singleton
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3896 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Handle multiple concurrent PPP connections.
* src/ppp-manager/nm-ppp-manager.c
src/ppp-manager/nm-ppp-manager.h
- (constructor): only PPP Manager request bus name once; each
NMPPPManager object gets a unique object path
- (nm_ppp_manager_class_init, get_property, set_property,
nm_ppp_manager_new, nm_ppp_manager_start): pass parent interface in
at construct time
- (impl_ppp_manager_need_secrets, impl_ppp_manager_set_state): don't
remove timeout until PPP manager gets an IP4 config
- (create_pppd_cmd_line): pass dbus object path as 'ipparam' so that
the plugin can call back to this specific PPP manager instance
* src/nm-device-ethernet.c
src/nm-serial-device.c
- Pass parent device in nm_ppp_manager_new()
* src/nm-gsm-device.c
src/nm-cdma-device.c
- (device_state_changed): don't close serial device on NEED_AUTH
state changed, that's not a failure case like the rest are
* src/ppp-manager/nm-pppd-plugin.c
- (nm_ip_up): always use index 0 into the ipcp options, because NM always
binds one interface to any pppd process, thus the correct index
is always 0; send PHASE_DEAD on error to alert NM immediately of
problems; try harder to get a peer address in spite of pppd
- (plugin_init): use 'ipparam' as the object path back to our specific
PPP manager instance
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3894 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/ppp-manager/nm-ppp-manager.c
- (impl_ppp_manager_need_secrets): rework to handle secrets better;
since the GSM and CDMA settings now implement need_secrets, we can
rely on them to do the right thing. Where secrets are not required,
just pass empty strings back to the pppd plugin.
- (nm_ppp_manager_update_secrets): leak fix; don't need to dup the strings
- (impl_ppp_manager_set_ip4_config): clear the secrets tries counter
on successful IP4 config receipt
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3893 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-util/nm-setting-cdma.c
libnm-util/nm-setting-gsm.c
- (verify): validate username & password if they exist
- (need_secrets): if username given, require a password too
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3892 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/dnsmasq-manager/nm-dnsmasq-manager.c
- (create_dm_cmd_line): really don't listen on lo, despite what the
manpage says about --listen-address without --interface
(bgo #546033)
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3890 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-glib/nm-device.c
- (proxy_get_string): util function for querying a HAL property
- (get_ancestor_device): split out from get_product_and_vendor()
- (get_product_and_vendor): simplify; get more accurate pid & vid info
from PCI devices by querying subsys properties
- (nm_device_update_description): simplify
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3883 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-util/nm-setting-ip4-config.c
libnm-util/nm-setting-ip4-config.h
- Make IPv4 methods reflect their usage; 'dhcp' -> 'auto' and
'autoip' -> 'link-local'. VPN & PPP connections can also have IPv4
settings, and they don't necessarily use DHCP.
* src/NetworkManagerPolicy.c
src/nm-device.c
system-settings/plugins/ifcfg-fedora/reader.c
system-settings/plugins/ifcfg-suse/parser.c
- Fixup for method changes
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3882 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-activation-request.c
src/vpn-manager/nm-vpn-connection.c
- Correct GetSecrets D-Bus pending call usage; the GetSecrets call
itself should be attached to the activation request or the VPN
connection, not the NMConnection object, since the call is not
expected to live as long as the NMConnection itself
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3880 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-wifi.c
- (real_act_stage2_config): fix issue where association would continue
even though secrets were needed; 'goto out' was in wrong scope and
result of handle_auth_or_fail() should have been dumped directly to
'ret' to ensure that the association was postponed until secrets
are available
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3879 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-serial-device.c
- (nm_serial_device_wait_for_reply): fix timeout calculation. Since
time(2) is used for current time, which returns seconds, we shouldn't
be multiplying by 1000.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3871 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Patch from Fabrice Bellet <fabrice@bellet.info>
* src/NetworkManagerSystem.c
- (route_in_same_subnet): mask addresses and compare them so that the
function actually does what it says it's going to do (rh #456685)
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3868 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-util/nm-setting-ip6-config.c
- (set_property): add missing break that caused routes to be overwritten
with addresses
* libnm-util/nm-setting-ip6-config.c
- (verify): validate routes and return GError everywhere on invalid setting
- (finalize): don't leak routes
- (set_property): add missing break that caused routes to be overwritten
with addresses
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3865 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/dnsmasq-manager/nm-dnsmasq-manager.c
src/nm-device.c
src/ppp-manager/nm-ppp-manager.c
- Ensure child process gets reaped. The child watch function may be
removed from the mainloop before the child gets killed, so we have
to make sure the child is reaped when it's told to die intentionally
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3857 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/ppp-manager/nm-ppp-manager.c
- (create_pppd_cmd_line): send 'noipdefault' on non-PPPoE connections
to prevent pppd from picking up some random local address from an
interface that doesn't have anything to do with the one we're
interested in (rh #455348)
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3842 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-util/nm-utils.c
- (string_to_utf8): general function for conversion to UTF-8 assisted
by locale
- (nm_utils_ssid_to_utf8): use string_to_utf8()
- (nm_utils_garray_to_string): ensure returned string is UTF-8 safe
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3830 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* introspection/Makefile.am
introspection/nm-device.xml
introspection/nm-dhcp4-config.xml
- Add bits for the DHCP4Config property of the device, and the DHCP4Config
itself
* src/nm-device-interface.c
src/nm-device-interface.h
- Add the DHCP4Config property
* src/nm-device.c
- Keep track of DHCP4 options via a new DHCP4Config property and notify
D-Bus clients when it changes
* src/nm-dhcp4-config.c
src/nm-dhcp4-config.h
- Simple object to store DHCP4 options, export them over D-Bus, and
notify when they change
* src/dhcp-manager/nm-dhcp-manager.c
src/dhcp-manager/nm-dhcp-manager.h
- (nm_dhcp_manager_set_dhcp4_config, copy_dhcp4_config_option): copy and
filter server-returned DHCP options into an NMDHCP4Config object
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3829 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Patch from Roy Marples <roy@marples.name>
* configure.in
- Add --with-dhcp-client option
* src/dhcp-manager/Makefile.am
- pass DHCP_CLIENT_PATH on compile line
* src/dhcp-manager/nm-dhcp-manager.c
src/dhcp-manager/nm-dhcp-manager.h
- Genericize for both dhcpcd and dhclient
* src/dhcp-manager/nm-dhcp-dhclient.c
- Move dhclient stuff out to it's own file from nm-dhcp-manager.c
* src/dhcp-manager/nm-dhcp-dhcpcd.c
- Implement support for dhcpcd too
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3823 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/src/nm-system-config-interface.c
(nm_system_config_interface_supports_add): Implement.
(nm_system_config_interface_add_connection): Return a boolean to notify
of errors.
* system-settings/src/nm-polkit-helpers.c:
* system-settings/src/nm-polkit-helpers.h: Move error declarations to
a separate file.
* system-settings/src/dbus-settings.c (impl_settings_add_connection):
Return an error when none of the plugins support add or if addition
failed for some reason.
* system-settings/src/nm-system-config-error.h:
* system-settings/src/nm-system-config-error.c: New files, mostly moved
here from nm-polkit-helpers.[ch].
* system-settings/src/Makefile.am: Build new files.
* system-settings/plugins/keyfile/reader.c
(read_array_of_array_of_uint): Make it more general so that it would
work for routes as well.
* system-settings/plugins/keyfile/writer.c
(write_array_of_array_of_uint): Ditto.
Fix the netmask/prefix writing.
* system-settings/plugins/keyfile/plugin.c (add_connection): Return
boolean to notify errors.
* system-settings/plugins/ifcfg-suse/nm-suse-connection.c (update):
Return more specific error.
(delete): Ditto.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3821 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Modify the NMDevice::state-changed signal to include the previous state
and reason. Enables the applet to provide more information why device
activation failed.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3819 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* 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
* 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
* 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
* 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
* 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
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
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
* 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
* 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
* 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
* 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
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
* 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
* 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
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
* 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
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
* 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
* 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
* 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
* 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
* 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
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
* 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
* 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
* 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
* src/nm-device-private.h
- Remove unused prototypes and clean up
* src/nm-device.c
- Remove anything related to system_config_data, which is no longer used
- (nm_device_new_ip4_autoip_config): make static
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3707 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/plugins/ifcfg-suse/nm-suse-connection.c
(file_changed): Fix a bug where suse system settings plugin didn't
update the connections automatically when the files changed.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3700 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-util/nm-setting-wireless.c
libnm-util/nm-setting-wireless.h
- (set_property, get_property, nm_setting_wireless_class_init): add the
'adhoc-create' property, which when TRUE indicates that NM should
create this connection as an adhoc wifi network if it's not found
as an adhoc network during scanning. Can be used to auto-create
adhoc networks when used in combination with autoconnect.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3697 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Patch from Dennis Noordsij <dennis.noordsij@helsinki.fi>.
* src/nm-gsm-device.c: Don't try to reset the modem before PIN is
checked, it doesn't work on some devices.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3696 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/ppp-manager/nm-ppp-manager.c (nm_ppp_manager_stop): Make sure
pppd gets killed, if SIGTERM doesn't do it's job, SIGKILL it.
* src/dhcp-manager/nm-dhcp-manager.c (nm_dhcp_manager_get_ip4_config):
Use inet_aton() everywhere to improve error detection.
Don't fall back to 'dhcp_server_identifier' if the gateway is not
provided.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3695 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/supplicant-manager/nm-supplicant-settings-verify.c
- Switch 'bssid' from bytes to keyword type
- (validate_type_keyword): allow NULL keyword lists
* src/supplicant-manager/nm-supplicant-config.c
- (nm_supplicant_config_add_setting_wireless): convert the bssid from
a byte array to string form, which is what the supplicant expects
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3686 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Add a flag to NMSettingIP4Config to make it possible to ignore the DNS
information received from DHCP.
* libnm-util/nm-setting-ip4-config.c: Add a new membet "ignore_dhcp_dns"
to make it possible to ignore the DNS information (both servers and
searches) returned by DHCP server.
* src/NetworkManagerUtils.c (nm_utils_merge_ip4_config): Reset the
name servers and searches if "ignore_dhcp_dns" is set.
* src/nm-ip4-config.c (nm_ip4_config_reset_nameservers)
(nm_ip4_config_reset_searches): Implement.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3685 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Remove anything mDNS related. This is better done from a distro-specific
dispatcher script. Plus, any distro using avahi doesn't need to restart
avahi, since avahi can handle interface changes just fine using netlink.
* configure.in
- Remove --with-mdns-provider
* src/NetworkManagerPolicy.c
- (global_state_changed): don't restart the mdns provider
* src/NetworkManagerSystem.h
src/backends/NetworkManagerArch.c
src/backends/NetworkManagerDebian.c
src/backends/NetworkManagerFrugalware.c
src/backends/NetworkManagerGentoo.c
src/backends/NetworkManagerMandriva.c
src/backends/NetworkManagerPaldo.c
src/backends/NetworkManagerRedHat.c
src/backends/NetworkManagerSlackware.c
src/backends/NetworkManagerSuSE.c
- (nm_system_restart_mdns_responder): remove
* src/backends/NetworkManagerGeneric.c
src/backends/NetworkManagerGeneric.h
- (nm_generic_restart_mdns_responder): remove
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3684 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Don't remove all devices on waking up, sync with HAL.
* src/nm-manager.c (nm_manager_udi_is_managed): Implement.
(sync_devices): Implement, based on hal_manager_hal_reappeared_cb.
(hal_manager_hal_reappeared_cb): Just call sync_devices.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3680 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-gsm-device.c (device_state_changed): Make sure we don't leave the
serial device open when we're not connecting or connected.
* src/nm-cdma-device.c (device_state_changed): Ditto.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3679 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/plugins/ifcfg-fedora/reader.c
- (make_ip4_setting): get a fallback gateway from /etc/sysconfig/network
if the ifcfg doesn't specify one
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3675 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Make the system settings service exit when the bus goes away. Since it's
a bus-activated service, it's lifetime is limited to the bus that activated
it (rh #444976).
* system-settings/src/Makefile.am
system-settings/src/nm-system-config-hal-manager-private.h
- Remove nm-system-config-hal-manager-private.h
* system-settings/src/nm-system-config-hal-manager.c
- (nm_system_config_hal_manager_reinit_dbus,
nm_system_config_hal_manager_deinit_dbus): remove
* system-settings/src/main.c
- (dbus_reconnect): remove
- (dbus_cleanup): don't tell the HAL manager to deinit dbus
- (destroy_cb): just quit when the bus goes away
- (start_dbus_service, dbus_init): simplify
- (main): destroy the wired devices hash table after destroying
the HAL manager so we don't have to disconnect signals from the
HAL manager
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3674 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Move crypto functions from nm-applet to libnm-util.
* libnm-util/nm-setting-8021x.c (nm_setting_802_1x_set_ca_cert)
(nm_setting_802_1x_set_client_cert)
(nm_setting_802_1x_set_phase2_ca_cert)
(nm_setting_802_1x_set_phase2_client_cert)
(nm_setting_802_1x_set_private_key)
(nm_setting_802_1x_set_phase2_private_key): Implement. Given a certificate
file (or private key and it's password), read the certificate data.
* libnm-util/crypto_nss.c:
* libnm-util/crypto_gnutls.c:
* libnm-util/crypto.[ch]: Move here from nm-applet.
* configure.in: Check for NSS and gnutls here (moved here from nm-applet).
* system-settings/plugins/ifcfg-suse/parser.c (read_wpa_eap_settings):
Imlement WPA-EAP configuration reading from sysconfig.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3673 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Fix Linus' bug in rh #134886
* src/nm-device-802-3-ethernet.c
- (constructor): request initial carrier state
* src/nm-netlink-monitor.c
- (nm_netlink_monitor_request_status): schedule emission of carrier
signals after refilling the link cache. Because the refill is a
synchronous operation, the normal message hander won't get called
since libnl has already consumed the messages.
- (deferred_emit_carrier_state): emit carrier states from an idle handler
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3669 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Fix refcounting issues over sleep/wake when a VPN connection was active that
caused NM to try registering an object path for a device upon wake that was
the same as an already registered object path.
* src/nm-device.c
- (nm_device_take_down): properly handle cases where the device is
no longer active but was just active, and therefore must be
deactivated. When a device moves to unmanaged mode, this function
previously would not deactivate the device, because the state was
already unmanaged by the time this function was called.
* src/vpn-manager/nm-vpn-connection.c
- (device_state_changed): properly handle multiple devices states in
which the device is now deactivated. Code previously didn't handle
transitions to the UNAVAILABLE (like rfkill or carrier off) and
UNMANAGED states.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3667 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/nm-device-private.h
src/nm-device.c
- (nm_device_hw_bring_up, nm_device_hw_take_down): export
* src/nm-device-802-11-wireless.c
- (nm_device_802_11_wireless_set_enabled): take devices up
and down as appropriate for the rfkill state
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3666 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* marshallers/nm-marshal.list
- Add VOID:POINTER,STRING marshaller for ifcfg-fedora plugin
* system-settings/plugins/ifcfg-fedora/Makefile.am
system-settings/plugins/ifcfg-fedora/nm-inotify-helper.c
system-settings/plugins/ifcfg-fedora/nm-inotify-helper.h
- Implement a minimal inotify helper for watch paths for IN_CLOSE_WRITE
events. Solely for use watching ifcfg files to pick up changes
to their hardlinks, since GIO doesn't support this yet (bgo #532815)
* system-settings/plugins/ifcfg-fedora/nm-ifcfg-connection.c
- (nm_ifcfg_connection_class_init): new 'ifcfg-changed' signal when the
file contents change
- (finalize): clean up inotify watches
- (nm_ifcfg_connection_new): store keyfile; inotify watch the keyfile
and the connection ifcfg for changes on their hardlinks
- (files_changed_cb): proxy the changed signal back out to listeners
* system-settings/plugins/ifcfg-fedora/plugin.c
- (dir_changed):
- (connection_ifcfg_changed): re-read the connection when the ifcfg
changes
- (read_one_connection): connect to change signals on the new connection
- (dir_changed, connection_changed_handler,
handle_connection_remove_or_new): break out connection change
handling and connection new/remove handling so it can be used from
both the GFileMonitor callback and the NMIfcfgConnection changed
signals
* system-settings/plugins/ifcfg-fedora/reader.c
system-settings/plugins/ifcfg-fedora/reader.h
- (connection_from_file): return the keyfile path the connection would use
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3663 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/src/nm-polkit-helpers.c (create_polkit_context): Use a
single PolKitContext which is shared by all. PolKitContext::unref leaks
just about everything, including all open file descriptiors and results
in 99% cpu usage when data arrives to any of the fds that don't belong
to any context anymore.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3662 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* gfilemonitor/glocaldirectorymonitor.c
gfilemonitor/glocaldirectorymonitor.h
- (g_local_directory_monitor_constructor): actually subscribe to the
watch
- (_g_local_directory_monitor_new): ensure that inotify is started up
* gfilemonitor/glocalfilemonitor.c
gfilemonitor/glocalfilemonitor.h
- (g_local_file_monitor_constructor): actually subscribe to the watch
- (_g_local_file_monitor_new): ensure that inotify is started up
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3661 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* configure.in
- record PolicyKit version
* system-settings/src/nm-polkit-helpers.c
- (check_polkit_privileges): use polkit_context_can_caller_do_action()
with PolicyKit <= 0.6
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3658 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Update Fedora system-settings plugin to support latest API and use
GFileMonitor rather than home-rolled inotify code.
* system-settings/plugins/ifcfg-fedora/Makefile.am
system-settings/plugins/ifcfg-fedora/common.h
system-settings/plugins/ifcfg-fedora/plugin.c
- Update to latest system settings plugin API; use GIO instead of
custom inotify code; use NMIfcfgConnection objects instead of
ConnectionData structures tacked onto NMConnection objects
* system-settings/plugins/ifcfg-fedora/nm-ifcfg-connection.c
system-settings/plugins/ifcfg-fedora/nm-ifcfg-connection.h
- Implement an NMExportedConnection subclass mapping ifcfg files to
connections
* system-settings/plugins/ifcfg-fedora/reader.c
system-settings/plugins/ifcfg-fedora/reader.h
- Move ifcfg parsing bits here from parser.c
* system-settings/plugins/ifcfg-fedora/parser.c
system-settings/plugins/ifcfg-fedora/parser.h
- Remove; most code moved to reader.c
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3656 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* configure.in
Makefile.am
gfilemonitor/*
- Add a private copy of the GIO GFileMonitor code, with a custom GFile
implementation, so that the same change monitoring code can be used
on systems without glib-2.14 (like Fedora 8)
* system-settings/plugins/keyfile/Makefile.am
system-settings/plugins/keyfile/plugin.c
system-settings/plugins/ifcfg-suse/Makefile.am
system-settings/plugins/ifcfg-suse/plugin.c
- Use private gfilemonitor code if GIO is not present
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3654 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
Use PolicyKit to authorize the system settings' AddConnection method
and the system settings connections' Update and Delete methods.
* libnm-glib/nm-settings.c (impl_exported_connection_update)
(impl_exported_connection_delete, nm_exported_connection_update)
(nm_exported_connection_delete): Return boolean and fill GError
to notify the callers of the reasons why it might have failed.
* libnm-glib/nm-dbus-settings-system.c
(nm_dbus_settings_system_add_connection): Return the error from dbus
call so that the callers can see why it failed.
* libnm-glib/nm-dbus-connection.c (update, delete): Update the
signatures.
* system-settings/src/nm-polkit-helpers.[ch]: Implement.
* system-settings/src/nm-sysconfig-connection.[ch]: Implement. New
abstract base class that checks PolicyKit permissions.
* system-settings/src/dbus-settings.c:
(impl_settings_add_connection): Check the policy before carring out
the request.
* system-settings/plugins/keyfile/nm-keyfile-connection.c:
Inherit from NMSysconfigConnection, check the policies before
allowing updating or removing.
* system-settings/plugins/ifcfg-suse/nm-suse-connection.c:
Inherit from NMSysconfigConnection.
* introspection/nm-exported-connection.xml: Annotate "Update" and
"Delete" methods with async flag so that the implementations can get
access to DBusGMethodInvocation.
* system-settings/src/dbus-settings.c
(settings_add_connection_check_privileges): Implement.
(impl_settings_add_connection): Check the privileges before adding a new
connection. Improve error reporting.
* introspection/nm-settings-system.xml: Make the 'AddConnection' method
async so that the implementation can access DBusGMethodInvocation.
* configure.in: Check for PolicyKit.
* policy/org.freedesktop.network-manager-settings.system.policy:
New file.
* policy/Makefile.am: Install the policy file.
* configure.in: Add 'policy' subdir.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3646 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/plugins/keyfile/reader.c
- (read_one_setting_value): handle IP address items separately
- (read_array_of_uint): read IPv4 DNS option as a string array
- (read_array_of_array_of_uint): read IPv4 address tuples as a string
array
* system-settings/plugins/keyfile/writer.c
- (write_setting_value): handle IP address items separately
- (write_array_of_uint): handle IPv4 DNS option as a string array,
not an array of uint, so that it's user-editable
- (write_array_of_array_of_uint): handle IPv4 address tuples as string
arrays, so they are user-editable
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3643 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/plugins/keyfile/Makefile.am
- Change location of the keyfile plugin settings to
/etc/NetworkManager/system-connections
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3642 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* system-settings/plugins/keyfile/nm-keyfile-connection.[ch]: Implement.
* system-settings/plugins/keyfile/plugin.c: Work with
NMKeyfileConnections.
* system-settings/src/dbus-settings.c: Remove NMSysconfigExportedConnection.
Plugins are supposed to return NMExportedConnections now and handle the
updated(), removed(), and GetSecrets().
Store the internal list of connections in hash table to make it easier
to find duplicates.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3640 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* src/dhcp-manager/nm-dhcp-manager.c
- (nm_dhcp_manager_get_ip4_config): clean up; update for changes to
NMIP4Config to support multiple IP addresses
* src/NetworkManagerUtils.c
- (nm_utils_merge_ip4_config): update for multiple IP addresses
* src/nm-ip4-config.c
src/nm-ip4-config.h
- Store a list of IPv4 address/netmask/gateway tuples
- (nm_ip4_config_get_gateway, nm_ip4_config_set_gateway,
nm_ip4_config_get_netmask, nm_ip4_config_set_netmask,
nm_ip4_config_get_broadcast, nm_ip4_config_set_broadcast,
nm_ip4_config_set_address): remove
- (nm_ip4_config_take_address, nm_ip4_config_add_address,
nm_ip4_config_replace_address, nm_ip4_config_get_num_addresses):
new functions; handle multiple IPv4 addresses
* src/nm-device.c
src/ppp-manager/nm-ppp-manager.c
src/vpn-manager/nm-vpn-connection.c
src/NetworkManagerPolicy.c
test/nm-tool.c
libnm-glib/libnm-glib-test.c
- update for changes to NMIP4Config for multiple IPv4 addresses
* src/NetworkManagerSystem.c
- (nm_system_device_set_ip4_route): don't add the route if any address
is on the same subnet as the destination
- (check_one_address): ignore the exact match, just match family and
interface index
- (add_ip4_addresses): add all IPv4 addresses in an NMIP4Config to
an interface
- (nm_system_device_set_from_ip4_config): use add_ip4_addresses()
- (nm_system_vpn_device_set_from_ip4_config): use add_ip4_addresses()
* introspection/nm-ip4-config.xml
- Remove 'address', 'gateway', 'netmask', and 'broadcast' properties
- Add 'addresses' property which is an array of (uuu) tuples of
address/netmask/gateway
* libnm-util/nm-setting-ip4-config.c
- (set_property): use ip-address <-> GValue converters from nm-utils.c
* libnm-glib/nm-ip4-config.c
libnm-glib/nm-ip4-config.h
- Handle D-Bus interface changes to support multiple IP addresses
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3637 4912f4e0-d625-0410-9fb7-b9a5a253dbdc
* libnm-glib/nm-dbus-settings.c (constructor): Fix the
"PropertiesChanged" signal signature.
* libnm-glib/nm-dbus-connection.c (constructor): Use the common GType
defined in nm-dbus-glib-types.h.
Don't register the connection on dbus, we're a proxy class to
communicate with an already registered connection over dbus.
2008-04-30 Tambet Ingo <tambet@gmail.com>
Implement new subclasses of NMSettings and NMExportedConnection to make
it easier for the applet to access and modify system settings.
* libnm-glib/nm-dbus-connection.[ch]:
* libnm-glib/nm-dbus-settings.[ch]:
* libnm-glib/nm-dbus-settings-system.[ch]: Implement.
* libnm-glib/Makefile.am: Add the new files to build, generate some more
bindings and glue.
* include/NetworkManager.h: Define the system settings DBus interface.
2008-04-30 Tambet Ingo <tambet@gmail.com>
Implement additional C API for exported connections to make them identical
with the DBus API. Change the (list_connections) virtual function to be
more usable from C - instead of requiring implementers to return a GPtrArray
of dbus paths, return a list of connections.
* libnm-glib/nm-settings.c (nm_exported_connection_class_init): Fix a typo.
(nm_settings_list_connections):
(nm_exported_connection_new):
(nm_exported_connection_update):
(nm_exported_connection_delete): Implement.
(impl_settings_list_connections):
(impl_exported_connection_update):
(impl_exported_connection_delete): Use the new public functions to make
sure the C and dbus interfaces stay in sync.
* system-settings/src/dbus-settings.c (list_connections): Return a list of
connections.
git-svn-id: http://svn-archive.gnome.org/svn/NetworkManager/trunk@3630 4912f4e0-d625-0410-9fb7-b9a5a253dbdc