From d6201f5d8daada3d64a0a3e0038e14eebec683ce Mon Sep 17 00:00:00 2001 From: Michael Biebl Date: Wed, 3 Aug 2016 22:59:23 +0200 Subject: Imported Upstream version 1.2.4 --- Makefile.in | 5 +- NEWS | 39 +- callouts/Makefile.in | 1 + callouts/tests/Makefile.in | 1 + clients/Makefile.in | 1 + clients/cli/Makefile.in | 1 + clients/cli/common.c | 10 +- clients/cli/connections.c | 40 +- clients/cli/devices.c | 2 + clients/cli/general.c | 18 +- clients/cli/nmcli-completion | 13 +- clients/cli/settings-docs.c | 6 +- clients/cli/settings.c | 242 ++++-- clients/common/nm-vpn-helpers.c | 133 ++- clients/common/nm-vpn-helpers.h | 7 +- clients/tui/Makefile.in | 1 + clients/tui/newt/Makefile.in | 1 + clients/tui/nmtui-edit.c | 9 +- config.h.in | 4 + configure | 62 +- configure.ac | 17 +- data/Makefile.in | 1 + ...rkManager-wait-online-systemd-pre200.service.in | 2 + data/NetworkManager-wait-online.service.in | 2 + data/NetworkManager.service.in | 2 + docs/Makefile.in | 1 + docs/api/Makefile.in | 1 + docs/api/html/NetworkManager.conf.html | 29 +- docs/api/html/NetworkManager.devhelp2 | 3 + docs/api/html/NetworkManager.html | 29 +- ...s-org.freedesktop.NetworkManager.IP4Config.html | 10 + ...s-org.freedesktop.NetworkManager.IP6Config.html | 10 + .../html/gdbus-org.freedesktop.NetworkManager.html | 38 + docs/api/html/index.html | 2 +- docs/api/html/index.sgml | 3 + docs/api/html/ix01.html | 6 + docs/api/html/nm-settings.html | 12 + docs/api/html/nmcli-examples.html | 3 +- docs/api/html/ref-settings.html | 12 + docs/api/settings-spec.xml | 2 + docs/api/version.xml | 2 +- docs/libnm-glib/Makefile.in | 1 + docs/libnm-glib/html/NMClient.html | 16 + docs/libnm-glib/html/index.html | 2 +- docs/libnm-glib/html/index.sgml | 2 + docs/libnm-glib/html/libnm-glib.devhelp2 | 2 + docs/libnm-glib/version.xml | 2 +- docs/libnm-util/Makefile.in | 1 + docs/libnm-util/html/NMConnection.html | 2 +- docs/libnm-util/html/NMSetting.html | 2 +- docs/libnm-util/html/NMSetting8021x.html | 2 +- docs/libnm-util/html/NMSettingAdsl.html | 2 +- docs/libnm-util/html/NMSettingBluetooth.html | 2 +- docs/libnm-util/html/NMSettingBond.html | 2 +- docs/libnm-util/html/NMSettingBridge.html | 2 +- docs/libnm-util/html/NMSettingBridgePort.html | 2 +- docs/libnm-util/html/NMSettingCdma.html | 2 +- docs/libnm-util/html/NMSettingConnection.html | 2 +- docs/libnm-util/html/NMSettingDcb.html | 2 +- docs/libnm-util/html/NMSettingGeneric.html | 2 +- docs/libnm-util/html/NMSettingGsm.html | 2 +- docs/libnm-util/html/NMSettingIP4Config.html | 4 +- docs/libnm-util/html/NMSettingIP6Config.html | 4 +- docs/libnm-util/html/NMSettingInfiniband.html | 2 +- docs/libnm-util/html/NMSettingOlpcMesh.html | 2 +- docs/libnm-util/html/NMSettingPPP.html | 2 +- docs/libnm-util/html/NMSettingPPPOE.html | 2 +- docs/libnm-util/html/NMSettingSerial.html | 2 +- docs/libnm-util/html/NMSettingTeam.html | 2 +- docs/libnm-util/html/NMSettingTeamPort.html | 2 +- docs/libnm-util/html/NMSettingVPN.html | 2 +- docs/libnm-util/html/NMSettingVlan.html | 2 +- docs/libnm-util/html/NMSettingWimax.html | 2 +- docs/libnm-util/html/NMSettingWired.html | 2 +- docs/libnm-util/html/NMSettingWireless.html | 2 +- .../libnm-util/html/NMSettingWirelessSecurity.html | 2 +- docs/libnm-util/html/index.html | 2 +- docs/libnm-util/html/libnm-util-nm-utils.html | 2 +- docs/libnm-util/html/object-tree.html | 4 +- docs/libnm-util/version.xml | 2 +- docs/libnm/Makefile.in | 1 + docs/libnm/html/NMClient.html | 17 +- docs/libnm/html/NMConnection.html | 2 +- docs/libnm/html/NMDevice.html | 2 +- docs/libnm/html/NMSetting.html | 4 +- docs/libnm/html/NMSetting8021x.html | 2 +- docs/libnm/html/NMSettingConnection.html | 2 +- docs/libnm/html/NMSettingDcb.html | 2 +- docs/libnm/html/NMSettingIP6Config.html | 2 +- docs/libnm/html/NMSettingIPConfig.html | 151 +++- docs/libnm/html/NMSettingMacvlan.html | 2 +- docs/libnm/html/NMSettingSerial.html | 2 +- docs/libnm/html/NMSettingTun.html | 2 +- docs/libnm/html/NMSettingVlan.html | 4 +- docs/libnm/html/NMSettingWired.html | 2 +- docs/libnm/html/NMSettingWireless.html | 2 +- docs/libnm/html/NMSettingWirelessSecurity.html | 2 +- docs/libnm/html/NMVpnEditorPlugin.html | 4 +- docs/libnm/html/api-index-full.html | 22 +- docs/libnm/html/index.html | 2 +- docs/libnm/html/index.sgml | 10 +- docs/libnm/html/libnm-nm-dbus-interface.html | 4 +- docs/libnm/html/libnm-nm-errors.html | 9 +- docs/libnm/html/libnm-nm-utils.html | 2 +- docs/libnm/html/libnm-nm-version.html | 28 +- docs/libnm/html/libnm-nm-vpn-dbus-interface.html | 2 +- docs/libnm/html/libnm.devhelp2 | 10 +- docs/libnm/html/object-tree.html | 8 +- docs/libnm/libnm-sections.txt | 6 +- docs/libnm/version.xml | 2 +- examples/C/Makefile.in | 1 + examples/C/glib/Makefile.in | 1 + examples/C/qt/Makefile.in | 1 + examples/Makefile.in | 1 + examples/dispatcher/Makefile.in | 1 + examples/lua/Makefile.in | 1 + examples/lua/lgi/Makefile.in | 1 + examples/python/Makefile.in | 1 + examples/python/dbus/Makefile.in | 1 + examples/python/gi/Makefile.in | 1 + examples/python/python-networkmanager/Makefile.in | 1 + examples/ruby/Makefile.in | 1 + examples/shell/Makefile.in | 1 + introspection/Makefile.in | 1 + introspection/nm-ip4-config.xml | 7 + introspection/nm-ip6-config.xml | 7 + introspection/nm-manager.xml | 28 + ...ig-org.freedesktop.NetworkManager.IP4Config.xml | 10 + ...ig-org.freedesktop.NetworkManager.IP6Config.xml | 10 + ...dbus-manager-org.freedesktop.NetworkManager.xml | 33 + libnm-core/Makefile.in | 1 + libnm-core/nm-connection.c | 29 +- libnm-core/nm-core-enum-types.c | 1 + libnm-core/nm-errors.h | 2 + libnm-core/nm-setting-ip-config.c | 62 ++ libnm-core/nm-setting-ip-config.h | 4 + libnm-core/nm-setting-ip4-config.c | 12 + libnm-core/nm-setting-ip6-config.c | 12 + libnm-core/nm-setting.c | 2 +- libnm-core/nm-utils.c | 2 +- libnm-core/nm-version.h | 14 +- libnm-core/nm-vpn-editor-plugin.c | 2 +- libnm-core/tests/Makefile.in | 1 + libnm-core/tests/test-general.c | 97 +++ libnm-glib/Makefile.in | 1 + libnm-glib/nm-client.c | 17 +- libnm-glib/nm-client.h | 8 +- libnm-glib/nm-device.c | 10 + libnm-glib/nm-glib-enum-types.c | 2 + libnm-glib/tests/Makefile.in | 1 + libnm-util/Makefile.in | 1 + libnm-util/nm-version.h | 14 - libnm-util/tests/Makefile.in | 1 + libnm/Makefile.am | 1 + libnm/Makefile.in | 4 +- libnm/libnm.ver | 4 + libnm/nm-client.h | 7 +- libnm/nm-device.c | 10 + libnm/nm-enum-types.c | 2 + libnm/nm-manager.c | 17 +- libnm/nm-property-docs.xml | 2 + libnm/nm-setting-docs.xml | 2 + libnm/tests/Makefile.in | 1 + man/Makefile.in | 1 + man/NetworkManager.8 | 14 +- man/NetworkManager.conf.5 | 34 +- man/NetworkManager.conf.xml | 27 +- man/NetworkManager.xml | 29 +- man/common.ent.in | 1 + man/nm-online.1 | 6 +- man/nm-settings-ifcfg-rh.5 | 6 +- man/nm-settings-ifcfg-rh.xml | 2 +- man/nm-settings-keyfile.5 | 6 +- man/nm-settings-keyfile.xml | 2 +- man/nm-settings.5 | 26 +- man/nm-settings.xml | 4 +- man/nmcli-examples.7 | 7 +- man/nmcli-examples.xml | 3 +- man/nmcli.1 | 6 +- man/nmtui.1 | 6 +- po/POTFILES.in | 1 - po/POTFILES.skip | 1 + policy/Makefile.in | 1 + policy/org.freedesktop.NetworkManager.policy.in.in | 10 + shared/Makefile.am | 1 + shared/Makefile.in | 2 + shared/nm-common-macros.h | 43 + shared/nm-glib.h | 18 + shared/nm-macros-internal.h | 21 +- shared/nm-version-macros.h | 7 +- shared/nm-version-macros.h.in | 5 +- src/Makefile.am | 10 +- src/Makefile.in | 67 +- src/NetworkManagerUtils.c | 1 + src/devices/Makefile.in | 1 + src/devices/adsl/Makefile.in | 1 + src/devices/bluetooth/Makefile.in | 1 + src/devices/bluetooth/nm-bluez-device.c | 88 +- src/devices/nm-device-bond.c | 2 +- src/devices/nm-device-tun.c | 7 + src/devices/nm-device-vxlan.c | 7 + src/devices/nm-device.c | 216 +++-- src/devices/nm-device.h | 4 + src/devices/nm-lldp-listener.c | 4 +- src/devices/team/Makefile.in | 1 + src/devices/team/nm-device-team.c | 14 +- src/devices/tests/Makefile.in | 1 + src/devices/wifi/Makefile.in | 1 + src/devices/wifi/nm-device-wifi.c | 2 + src/devices/wifi/tests/Makefile.in | 1 + src/devices/wwan/Makefile.in | 1 + src/dhcp-manager/Makefile.in | 1 + src/dhcp-manager/nm-dhcp-client.c | 2 + src/dhcp-manager/nm-dhcp-dhclient-utils.c | 26 +- src/dhcp-manager/nm-dhcp-dhclient.c | 13 +- src/dhcp-manager/nm-dhcp-dhcpcd.c | 15 +- src/dhcp-manager/tests/Makefile.in | 1 + src/dhcp-manager/tests/test-dhcp-dhclient.c | 41 + src/dns-manager/nm-dns-dnsmasq.c | 286 +++++-- src/dns-manager/nm-dns-manager.c | 953 +++++++++++++-------- src/dns-manager/nm-dns-manager.h | 66 +- src/dns-manager/nm-dns-plugin.c | 29 +- src/dns-manager/nm-dns-plugin.h | 26 +- src/dns-manager/nm-dns-unbound.c | 4 +- src/dns-manager/nm-dns-utils.c | 105 --- src/dns-manager/nm-dns-utils.h | 28 - src/dnsmasq-manager/nm-dnsmasq-manager.c | 36 +- src/dnsmasq-manager/tests/Makefile.in | 1 + src/main.c | 19 +- src/nm-active-connection.c | 385 +++++---- src/nm-audit-manager.h | 1 + src/nm-auth-utils.c | 3 +- src/nm-auth-utils.h | 17 +- src/nm-config-data.c | 2 + src/nm-config-data.h | 92 +- src/nm-config.c | 81 +- src/nm-config.h | 8 +- src/nm-connection-provider.c | 9 +- src/nm-connection-provider.h | 8 - src/nm-core-utils.c | 178 +++- src/nm-core-utils.h | 7 + src/nm-default-route-manager.c | 16 +- src/nm-enum-types.c | 67 +- src/nm-enum-types.h | 2 - src/nm-ip4-config.c | 59 +- src/nm-ip4-config.h | 5 + src/nm-ip6-config.c | 58 +- src/nm-ip6-config.h | 5 + src/nm-manager.c | 393 +++++++-- src/nm-policy.c | 70 +- src/nm-sleep-monitor-systemd.c | 258 ------ src/nm-sleep-monitor-upower.c | 134 --- src/nm-sleep-monitor.c | 396 +++++++++ src/nm-sleep-monitor.h | 14 +- src/platform/Makefile.in | 1 + src/platform/nm-linux-platform.c | 80 +- src/platform/nm-platform.h | 2 +- src/platform/tests/Makefile.in | 1 + src/platform/wifi/wifi-utils.c | 16 + src/platform/wifi/wifi-utils.h | 4 + src/ppp-manager/Makefile.in | 1 + src/rdisc/Makefile.in | 1 + src/rdisc/tests/Makefile.in | 1 + src/settings/nm-agent-manager.c | 4 +- src/settings/nm-agent-manager.h | 2 +- src/settings/nm-secret-agent.c | 4 + src/settings/nm-settings-connection.c | 177 ++-- src/settings/nm-settings-connection.h | 4 +- src/settings/nm-settings.c | 232 +++-- src/settings/nm-settings.h | 16 +- src/settings/plugins/Makefile.in | 1 + src/settings/plugins/ibft/Makefile.in | 1 + src/settings/plugins/ibft/tests/Makefile.in | 1 + src/settings/plugins/ifcfg-rh/Makefile.in | 1 + src/settings/plugins/ifcfg-rh/plugin.c | 4 +- src/settings/plugins/ifcfg-rh/reader.c | 5 + src/settings/plugins/ifcfg-rh/tests/Makefile.in | 1 + .../ifcfg-rh/tests/network-scripts/Makefile.in | 1 + src/settings/plugins/ifnet/Makefile.in | 1 + src/settings/plugins/ifnet/tests/Makefile.in | 1 + src/settings/plugins/ifupdown/Makefile.in | 1 + src/settings/plugins/ifupdown/tests/Makefile.in | 1 + src/settings/plugins/keyfile/Makefile.in | 1 + src/settings/plugins/keyfile/tests/Makefile.in | 1 + .../plugins/keyfile/tests/keyfiles/Makefile.in | 1 + src/supplicant-manager/tests/Makefile.in | 1 + src/supplicant-manager/tests/certs/Makefile.in | 1 + src/tests/Makefile.in | 1 + src/tests/config/Makefile.in | 1 + src/tests/config/test-config.c | 40 +- src/tests/test-general.c | 121 +++ src/vpn-manager/nm-vpn-connection.c | 120 ++- src/vpn-manager/nm-vpn-connection.h | 4 +- tools/Makefile.in | 1 + tools/test-networkmanager-service.py | 5 +- vapi/Makefile.in | 1 + 296 files changed, 4665 insertions(+), 2483 deletions(-) create mode 100644 shared/nm-common-macros.h delete mode 100644 src/dns-manager/nm-dns-utils.c delete mode 100644 src/dns-manager/nm-dns-utils.h delete mode 100644 src/nm-sleep-monitor-systemd.c delete mode 100644 src/nm-sleep-monitor-upower.c create mode 100644 src/nm-sleep-monitor.c diff --git a/Makefile.in b/Makefile.in index f23ec31e..127c8d3d 100644 --- a/Makefile.in +++ b/Makefile.in @@ -216,8 +216,8 @@ am__DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/NetworkManager.pc.in \ $(top_srcdir)/build-aux/tap-driver.sh ABOUT-NLS AUTHORS \ COPYING ChangeLog INSTALL NEWS README TODO build-aux/compile \ build-aux/config.guess build-aux/config.rpath \ - build-aux/config.sub build-aux/depcomp build-aux/install-sh \ - build-aux/ltmain.sh build-aux/missing + build-aux/config.sub build-aux/install-sh build-aux/ltmain.sh \ + build-aux/missing DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) distdir = $(PACKAGE)-$(VERSION) top_distdir = $(distdir) @@ -393,6 +393,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/NEWS b/NEWS index 93c6c61e..7eac1f93 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,32 @@ +============================================== +NetworkManager-1.2.4 +Overview of changes since NetworkManager-1.2.2 +============================================== + +This is a new stable release of NetworkManager. Notable changes include: + +* The timeout for requests of secrets to agents has been increased from 25 to + 120 seconds. +* NetworkManager now follows symlinks when accessing resolv.conf and + 'rc-manager=file'. +* Added new values 'symlink' and 'unmanaged' to rc-manager configuration option. +* It is now possible to configure the default rc-manager option at compile time. +* Name servers passed to dnsmasq now specify an egress interface to avoid + problems with multiple active connections. +* Reverse DNS entries for IPv6 are now added to dnsmasq, and IPv4 reverse + entries now honor the network prefix. +* A new 'dns-priority' property of ipv4 and ipv6 settings can be used to tweak + the order of servers in resolv.conf when multiple connections are active. +* Added a 'Reload' D-Bus method to reload configuration and reapply DNS + configuration. +* Now devices are disconnected before the system suspends, executing dispatcher + scripts. This allows external applications to be notified of the change in + connectivity. +* Devices without L3 configuration are not more put in DOWN state on shutdown. +* MTU settings are now applied also to devices without IPv4 configuration. +* Improved VPN support in nmcli. +* Many bug fixes. + ============================================ NetworkManager-1.2.2 Overview of changes since NetworkManager-1.2 @@ -22,10 +51,12 @@ Overview of changes since NetworkManager-1.0 This is a new stable release of NetworkManager. Notable changes include: -* Added an option to enable use of random MAC addresses for Wi-Fi access - point scanning (defaults to disabled). Controlled with - 'wifi.mac-address-randomization' property (MAC_ADDRESS_RANDOMIZATION key in - ifcfg files). +* MAC addresses during Wi-Fi access point scanning are now randomized + if wpa_supplicant supports PreassocMacAddr. +* Added an option to enable random MAC addresses for association to Wi-Fi access + point (defaults to disabled). Controlled with 'wifi.mac-address-randomization' + property (MAC_ADDRESS_RANDOMIZATION key in ifcfg files). Requires support from + wpa_supplicant. * Wi-Fi scanning now utilizes wpa_supplicant's AP list. * Added support for Wi-Fi powersave, configured with POWERSAVE key in ifcfg files. diff --git a/callouts/Makefile.in b/callouts/Makefile.in index e7a7f2aa..14c5dcb5 100644 --- a/callouts/Makefile.in +++ b/callouts/Makefile.in @@ -406,6 +406,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/callouts/tests/Makefile.in b/callouts/tests/Makefile.in index 6079f236..a4a80afb 100644 --- a/callouts/tests/Makefile.in +++ b/callouts/tests/Makefile.in @@ -526,6 +526,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/clients/Makefile.in b/clients/Makefile.in index a34052e7..b9439b75 100644 --- a/clients/Makefile.in +++ b/clients/Makefile.in @@ -360,6 +360,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/clients/cli/Makefile.in b/clients/cli/Makefile.in index d26384e1..01b2433a 100644 --- a/clients/cli/Makefile.in +++ b/clients/cli/Makefile.in @@ -341,6 +341,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/clients/cli/common.c b/clients/cli/common.c index 0888f063..05b76564 100644 --- a/clients/cli/common.c +++ b/clients/cli/common.c @@ -415,10 +415,12 @@ nmc_parse_and_build_route (int family, char *dest = NULL, *plen = NULL; const char *next_hop = NULL; const char *canon_dest; - long int prefix = max_prefix, metric = -1; + long int prefix = max_prefix; + unsigned long int tmp_ulong; NMIPRoute *route = NULL; gboolean success = FALSE; GError *local = NULL; + gint64 metric = -1; g_return_val_if_fail (family == AF_INET || family == AF_INET6, FALSE); g_return_val_if_fail (first != NULL, FALSE); @@ -444,19 +446,21 @@ nmc_parse_and_build_route (int family, next_hop = second; else { /* 'second' can be a metric */ - if (!nmc_string_to_int (second, TRUE, 0, G_MAXUINT32, &metric)) { + if (!nmc_string_to_uint (second, TRUE, 0, G_MAXUINT32, &tmp_ulong)) { g_set_error (error, 1, 0, _("the second component of route ('%s') is neither " "a next hop address nor a metric"), second); goto finish; } + metric = tmp_ulong; } } if (third) { - if (!nmc_string_to_int (third, TRUE, 0, G_MAXUINT32, &metric)) { + if (!nmc_string_to_uint (third, TRUE, 0, G_MAXUINT32, &tmp_ulong)) { g_set_error (error, 1, 0, _("invalid metric '%s'"), third); goto finish; } + metric = tmp_ulong; } route = nm_ip_route_new (family, dest, prefix, next_hop, metric, &local); diff --git a/clients/cli/connections.c b/clients/cli/connections.c index 1f1dae59..0e9a18ed 100644 --- a/clients/cli/connections.c +++ b/clients/cli/connections.c @@ -53,21 +53,6 @@ #define PROMPT_IP_TUNNEL_MODE _("Tunnel mode: ") #define PROMPT_MACVLAN_MODE _("MACVLAN mode: ") -static const char *nmc_known_vpns[] = { - "openvpn", - "vpnc", - "pptp", - "openconnect", - "openswan", - "libreswan", - "strongswan", - "ssh", - "l2tp", - "iodine", - "fortisslvpn", - NULL -}; - /* Available fields for 'connection show' */ static NmcOutputField nmc_fields_con_show[] = { {"NAME", N_("NAME")}, /* 0 */ @@ -1978,7 +1963,7 @@ device_state_cb (NMDevice *device, GParamSpec *pspec, gpointer user_data) && state == NM_DEVICE_STATE_FAILED) { if (nmc->print_output == NMC_PRINT_PRETTY) nmc_terminal_erase_line (); - g_print (_("Error: Connection activation failed.")); + g_print (_("Error: Connection activation failed.\n")); quit (); } else if (active && ac_state != NM_ACTIVE_CONNECTION_STATE_ACTIVATING) { g_string_printf (nmc->return_text, _("Error: Connection activation failed.")); @@ -2931,7 +2916,6 @@ check_valid_name (const char *val, const NameItem *array, const NameItem *array_ GError *tmp_err = NULL; int i; - g_return_val_if_fail (val, NULL); g_return_val_if_fail (array, NULL); /* Create a temporary array that can be used in nmc_string_is_valid() */ @@ -5904,10 +5888,12 @@ cleanup_bridge_slave: const char *user_c = NULL; char *user = NULL; const char *st; - char *service_type = NULL; + gs_free char *service_type_free = NULL; + const char *service_type = NULL; nmc_arg_t exp_args[] = { {"vpn-type", TRUE, &vpn_type, !ask}, {"user", TRUE, &user_c, FALSE}, {NULL} }; + gs_free const char **plugin_names = NULL; if (!nmc_parse_args (exp_args, FALSE, &argc, &argv, error)) return FALSE; @@ -5922,11 +5908,15 @@ cleanup_bridge_slave: if (vpn_type_ask) vpn_type = g_strstrip (vpn_type_ask); - if (!(st = nmc_string_is_valid (vpn_type, nmc_known_vpns, NULL))) { + plugin_names = nm_vpn_get_plugin_names (FALSE); + if (!(st = nmc_string_is_valid (vpn_type, plugin_names, NULL))) { g_print (_("Warning: 'vpn-type': %s not known.\n"), vpn_type); st = vpn_type; } - service_type = g_strdup_printf ("%s.%s", NM_DBUS_INTERFACE, st); + + service_type = nm_vpn_get_service_for_name (st); + if (!service_type) + service_type = service_type_free = nm_vpn_get_service_for_name_default (st); /* Also ask for all optional arguments if '--ask' is specified. */ user = g_strdup (user_c); @@ -5943,7 +5933,6 @@ cleanup_bridge_slave: success = TRUE; cleanup_vpn: g_free (vpn_type_ask); - g_free (service_type); g_free (user); if (!success) return FALSE; @@ -6711,7 +6700,10 @@ update_connection (gboolean persistent, static char * gen_func_vpn_types (const char *text, int state) { - return nmc_rl_gen_func_basic (text, state, nmc_known_vpns); + gs_free const char **plugin_names = NULL; + + plugin_names = nm_vpn_get_plugin_names (FALSE); + return nmc_rl_gen_func_basic (text, state, plugin_names); } static char * @@ -10690,7 +10682,7 @@ do_connection_import (NmCli *nmc, gboolean temporary, int argc, char **argv) } /* Import VPN configuration */ - plugin = nm_vpn_get_plugin_by_service (type, &error); + plugin = nm_vpn_lookup_plugin (type, NULL, &error); if (!plugin) { g_string_printf (nmc->return_text, _("Error: failed to load VPN plugin: %s."), error->message); @@ -10797,7 +10789,7 @@ do_connection_export (NmCli *nmc, int argc, char **argv) type = nm_setting_vpn_get_service_type (nm_connection_get_setting_vpn (connection)); /* Export VPN configuration */ - plugin = nm_vpn_get_plugin_by_service (type, &error); + plugin = nm_vpn_lookup_plugin (type, NULL, &error); if (!plugin) { g_string_printf (nmc->return_text, _("Error: failed to load VPN plugin: %s."), error->message); diff --git a/clients/cli/devices.c b/clients/cli/devices.c index 65c4be72..1e3d9e42 100644 --- a/clients/cli/devices.c +++ b/clients/cli/devices.c @@ -1716,6 +1716,8 @@ do_device_connect (NmCli *nmc, int argc, char **argv) nmc->nowait_flag = (nmc->timeout == 0); nmc->should_wait++; + nmc->connections = nm_client_get_connections (nmc->client); + /* Create secret agent */ nmc->secret_agent = nm_secret_agent_simple_new ("nmcli-connect"); if (nmc->secret_agent) diff --git a/clients/cli/general.c b/clients/cli/general.c index 0704688f..280630c1 100644 --- a/clients/cli/general.c +++ b/clients/cli/general.c @@ -25,6 +25,7 @@ #include "polkit-agent.h" #include "utils.h" #include "general.h" +#include "nm-common-macros.h" #include "devices.h" #include "connections.h" @@ -387,18 +388,6 @@ show_nm_status (NmCli *nmc, const char *pretty_header_name, const char *print_fl return TRUE; } -#define NM_AUTH_PERMISSION_ENABLE_DISABLE_NETWORK "org.freedesktop.NetworkManager.enable-disable-network" -#define NM_AUTH_PERMISSION_ENABLE_DISABLE_WIFI "org.freedesktop.NetworkManager.enable-disable-wifi" -#define NM_AUTH_PERMISSION_ENABLE_DISABLE_WWAN "org.freedesktop.NetworkManager.enable-disable-wwan" -#define NM_AUTH_PERMISSION_ENABLE_DISABLE_WIMAX "org.freedesktop.NetworkManager.enable-disable-wimax" -#define NM_AUTH_PERMISSION_SLEEP_WAKE "org.freedesktop.NetworkManager.sleep-wake" -#define NM_AUTH_PERMISSION_NETWORK_CONTROL "org.freedesktop.NetworkManager.network-control" -#define NM_AUTH_PERMISSION_WIFI_SHARE_PROTECTED "org.freedesktop.NetworkManager.wifi.share.protected" -#define NM_AUTH_PERMISSION_WIFI_SHARE_OPEN "org.freedesktop.NetworkManager.wifi.share.open" -#define NM_AUTH_PERMISSION_SETTINGS_MODIFY_SYSTEM "org.freedesktop.NetworkManager.settings.modify.system" -#define NM_AUTH_PERMISSION_SETTINGS_MODIFY_OWN "org.freedesktop.NetworkManager.settings.modify.own" -#define NM_AUTH_PERMISSION_SETTINGS_MODIFY_HOSTNAME "org.freedesktop.NetworkManager.settings.modify.hostname" - static const char * permission_to_string (NMClientPermission perm) { @@ -425,6 +414,10 @@ permission_to_string (NMClientPermission perm) return NM_AUTH_PERMISSION_SETTINGS_MODIFY_OWN; case NM_CLIENT_PERMISSION_SETTINGS_MODIFY_HOSTNAME: return NM_AUTH_PERMISSION_SETTINGS_MODIFY_HOSTNAME; + case NM_CLIENT_PERMISSION_SETTINGS_MODIFY_GLOBAL_DNS: + return NM_AUTH_PERMISSION_SETTINGS_MODIFY_GLOBAL_DNS; + case NM_CLIENT_PERMISSION_RELOAD: + return NM_AUTH_PERMISSION_RELOAD; default: return _("unknown"); } @@ -433,7 +426,6 @@ permission_to_string (NMClientPermission perm) static const char * permission_result_to_string (NMClientPermissionResult perm_result) { - switch (perm_result) { case NM_CLIENT_PERMISSION_RESULT_YES: return _("yes"); diff --git a/clients/cli/nmcli-completion b/clients/cli/nmcli-completion index 3c87f6f9..ffab7d8b 100644 --- a/clients/cli/nmcli-completion +++ b/clients/cli/nmcli-completion @@ -494,7 +494,7 @@ _nmcli_compl_ARGS() ;; vpn-type) if [[ "${#words[@]}" -eq 2 ]]; then - _nmcli_list "vpnc openvpn pptp openconnect openswan libreswan ssh l2tp iodine" + _nmcli_list "vpnc openvpn pptp openconnect openswan libreswan strongswan ssh l2tp iodine fortisslvpn" return 0 fi ;; @@ -579,10 +579,16 @@ _nmcli_compl_ARGS() user| \ username| \ service| \ - password| \ + password) + if [[ "${#words[@]}" -eq 2 ]]; then + return 0 + fi + ;; passwd-file| \ file) if [[ "${#words[@]}" -eq 2 ]]; then + compopt -o default + COMPREPLY=() return 0 fi ;; @@ -1379,8 +1385,7 @@ _nmcli() OPTIONS=(type file) OPTIONS_MANDATORY=(type file) - ALIASES=("type:vpn-type") - _nmcli_compl_ARGS ${ALIASES[@]} + _nmcli_compl_ARGS type:vpn-type return 0 fi ;; diff --git a/clients/cli/settings-docs.c b/clients/cli/settings-docs.c index f4fb6a15..3616ff87 100644 --- a/clients/cli/settings-docs.c +++ b/clients/cli/settings-docs.c @@ -251,6 +251,7 @@ NmcPropertyDesc setting_ipv4[] = { { "dhcp-timeout", "A timeout for a DHCP transaction in seconds." }, { "dns", "Array of IP addresses of DNS servers." }, { "dns-options", "Array of DNS options. NULL means that the options are unset and left at the default. In this case NetworkManager will use default options. This is distinct from an empty list of properties." }, + { "dns-priority", "DNS priority. The relative priority to be used when determining the order of DNS servers in resolv.conf. A lower value means that servers will be on top of the file. Zero selects the default value, which is 50 for VPNs and 100 for other connections. When multiple devices have configurations with the same priority, the one with an active default route will be preferred. Note that when using dns=dnsmasq the order is meaningless since dnsmasq forwards queries to all known servers at the same time. Negative values have the special effect of excluding other configurations with a greater priority value; so in presence of at least a negative priority, only DNS servers from configurations with the lowest priority value will be used." }, { "dns-search", "Array of DNS search domains." }, { "gateway", "The gateway associated with this configuration. This is only meaningful if \"addresses\" is also set." }, { "ignore-auto-dns", "When \"method\" is set to \"auto\" and this property to TRUE, automatically configured nameservers and search domains are ignored and only nameservers and search domains specified in the \"dns\" and \"dns-search\" properties, if any, are used." }, @@ -272,6 +273,7 @@ NmcPropertyDesc setting_ipv6[] = { { "dhcp-timeout", "A timeout for a DHCP transaction in seconds." }, { "dns", "Array of IP addresses of DNS servers." }, { "dns-options", "Array of DNS options. NULL means that the options are unset and left at the default. In this case NetworkManager will use default options. This is distinct from an empty list of properties." }, + { "dns-priority", "DNS priority. The relative priority to be used when determining the order of DNS servers in resolv.conf. A lower value means that servers will be on top of the file. Zero selects the default value, which is 50 for VPNs and 100 for other connections. When multiple devices have configurations with the same priority, the one with an active default route will be preferred. Note that when using dns=dnsmasq the order is meaningless since dnsmasq forwards queries to all known servers at the same time. Negative values have the special effect of excluding other configurations with a greater priority value; so in presence of at least a negative priority, only DNS servers from configurations with the lowest priority value will be used." }, { "dns-search", "Array of DNS search domains." }, { "gateway", "The gateway associated with this configuration. This is only meaningful if \"addresses\" is also set." }, { "ignore-auto-dns", "When \"method\" is set to \"auto\" and this property to TRUE, automatically configured nameservers and search domains are ignored and only nameservers and search domains specified in the \"dns\" and \"dns-search\" properties, if any, are used." }, @@ -423,8 +425,8 @@ NmcSettingDesc all_settings[] = { { "gsm", setting_gsm, 13 }, { "infiniband", setting_infiniband, 6 }, { "ip-tunnel", setting_ip_tunnel, 13 }, - { "ipv4", setting_ipv4, 19 }, - { "ipv6", setting_ipv6, 19 }, + { "ipv4", setting_ipv4, 20 }, + { "ipv6", setting_ipv6, 20 }, { "macvlan", setting_macvlan, 5 }, { "ppp", setting_ppp, 19 }, { "pppoe", setting_pppoe, 5 }, diff --git a/clients/cli/settings.c b/clients/cli/settings.c index 1651aab2..f2a504cc 100644 --- a/clients/cli/settings.c +++ b/clients/cli/settings.c @@ -272,20 +272,21 @@ NmcOutputField nmc_fields_setting_ip4_config[] = { SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS), /* 2 */ SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS_SEARCH), /* 3 */ SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS_OPTIONS), /* 4 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_ADDRESSES), /* 5 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_GATEWAY), /* 6 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTES), /* 7 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTE_METRIC), /* 8 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_ROUTES), /* 9 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_DNS), /* 10 */ - SETTING_FIELD (NM_SETTING_IP4_CONFIG_DHCP_CLIENT_ID), /* 11 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_TIMEOUT), /* 12 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_SEND_HOSTNAME), /* 13 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_HOSTNAME), /* 14 */ - SETTING_FIELD (NM_SETTING_IP4_CONFIG_DHCP_FQDN), /* 15 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_NEVER_DEFAULT), /* 16 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_MAY_FAIL), /* 17 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_DAD_TIMEOUT), /* 18 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS_PRIORITY), /* 5 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_ADDRESSES), /* 6 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_GATEWAY), /* 7 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTES), /* 8 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTE_METRIC), /* 9 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_ROUTES), /* 10 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_DNS), /* 11 */ + SETTING_FIELD (NM_SETTING_IP4_CONFIG_DHCP_CLIENT_ID), /* 12 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_TIMEOUT), /* 13 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_SEND_HOSTNAME), /* 14 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_HOSTNAME), /* 15 */ + SETTING_FIELD (NM_SETTING_IP4_CONFIG_DHCP_FQDN), /* 16 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_NEVER_DEFAULT), /* 17 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_MAY_FAIL), /* 18 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DAD_TIMEOUT), /* 19 */ {NULL, NULL, 0, NULL, FALSE, FALSE, 0} }; #define NMC_FIELDS_SETTING_IP4_CONFIG_ALL "name"","\ @@ -293,6 +294,7 @@ NmcOutputField nmc_fields_setting_ip4_config[] = { NM_SETTING_IP_CONFIG_DNS","\ NM_SETTING_IP_CONFIG_DNS_SEARCH","\ NM_SETTING_IP_CONFIG_DNS_OPTIONS","\ + NM_SETTING_IP_CONFIG_DNS_PRIORITY","\ NM_SETTING_IP_CONFIG_ADDRESSES","\ NM_SETTING_IP_CONFIG_GATEWAY","\ NM_SETTING_IP_CONFIG_ROUTES","\ @@ -315,18 +317,19 @@ NmcOutputField nmc_fields_setting_ip6_config[] = { SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS), /* 2 */ SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS_SEARCH), /* 3 */ SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS_OPTIONS), /* 4 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_ADDRESSES), /* 5 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_GATEWAY), /* 6 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTES), /* 7 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTE_METRIC), /* 8 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_ROUTES), /* 9 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_DNS), /* 10 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_NEVER_DEFAULT), /* 11 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_MAY_FAIL), /* 12 */ - SETTING_FIELD (NM_SETTING_IP6_CONFIG_IP6_PRIVACY), /* 13 */ - SETTING_FIELD (NM_SETTING_IP6_CONFIG_ADDR_GEN_MODE), /* 14 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_SEND_HOSTNAME), /* 15 */ - SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_HOSTNAME), /* 16 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DNS_PRIORITY), /* 5 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_ADDRESSES), /* 6 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_GATEWAY), /* 7 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTES), /* 8 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_ROUTE_METRIC), /* 9 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_ROUTES), /* 10 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_IGNORE_AUTO_DNS), /* 11 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_NEVER_DEFAULT), /* 12 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_MAY_FAIL), /* 13 */ + SETTING_FIELD (NM_SETTING_IP6_CONFIG_IP6_PRIVACY), /* 14 */ + SETTING_FIELD (NM_SETTING_IP6_CONFIG_ADDR_GEN_MODE), /* 15 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_SEND_HOSTNAME), /* 16 */ + SETTING_FIELD (NM_SETTING_IP_CONFIG_DHCP_HOSTNAME), /* 17 */ {NULL, NULL, 0, NULL, FALSE, FALSE, 0} }; #define NMC_FIELDS_SETTING_IP6_CONFIG_ALL "name"","\ @@ -334,6 +337,7 @@ NmcOutputField nmc_fields_setting_ip6_config[] = { NM_SETTING_IP_CONFIG_DNS","\ NM_SETTING_IP_CONFIG_DNS_SEARCH","\ NM_SETTING_IP_CONFIG_DNS_OPTIONS","\ + NM_SETTING_IP_CONFIG_DNS_PRIORITY","\ NM_SETTING_IP_CONFIG_ADDRESSES","\ NM_SETTING_IP_CONFIG_GATEWAY","\ NM_SETTING_IP_CONFIG_ROUTES","\ @@ -1041,19 +1045,30 @@ nmc_property_802_1X_get_ca_cert (NMSetting *setting, NmcPropertyGetType get_type } static char * -nmc_property_802_1X_get_client_cert (NMSetting *setting, NmcPropertyGetType get_type) +nmc_property_802_1X_get_client_cert (NMSetting *setting, + NmcPropertyGetType get_type, + gboolean show_secrets) { NMSetting8021x *s_8021X = NM_SETTING_802_1X (setting); NMSetting8021xCKScheme scheme; - char *client_cert_str = NULL; + char *cert_str = NULL; scheme = nm_setting_802_1x_get_client_cert_scheme (s_8021X); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) - client_cert_str = bytes_to_string (nm_setting_802_1x_get_client_cert_blob (s_8021X)); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) - client_cert_str = g_strdup (nm_setting_802_1x_get_client_cert_path (s_8021X)); + if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) { + if (show_secrets) + cert_str = bytes_to_string (nm_setting_802_1x_get_client_cert_blob (s_8021X)); + else + cert_str = g_strdup (_("")); + } else if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) + cert_str = g_strdup (nm_setting_802_1x_get_client_cert_path (s_8021X)); + + return cert_str; +} - return client_cert_str; +static char * +nmc_property_802_1X_get_client_cert_full (NMSetting *setting, NmcPropertyGetType get_type) +{ + return nmc_property_802_1X_get_client_cert (setting, get_type, TRUE); } static char * @@ -1073,19 +1088,30 @@ nmc_property_802_1X_get_phase2_ca_cert (NMSetting *setting, NmcPropertyGetType g } static char * -nmc_property_802_1X_get_phase2_client_cert (NMSetting *setting, NmcPropertyGetType get_type) +nmc_property_802_1X_get_phase2_client_cert (NMSetting *setting, + NmcPropertyGetType get_type, + gboolean show_secrets) { NMSetting8021x *s_8021X = NM_SETTING_802_1X (setting); NMSetting8021xCKScheme scheme; - char *phase2_client_cert_str = NULL; + char *cert_str = NULL; scheme = nm_setting_802_1x_get_phase2_client_cert_scheme (s_8021X); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) - phase2_client_cert_str = bytes_to_string (nm_setting_802_1x_get_phase2_client_cert_blob (s_8021X)); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) - phase2_client_cert_str = g_strdup (nm_setting_802_1x_get_phase2_client_cert_path (s_8021X)); + if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) { + if (show_secrets) + cert_str = bytes_to_string (nm_setting_802_1x_get_phase2_client_cert_blob (s_8021X)); + else + cert_str = g_strdup (_("")); + } else if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) + cert_str = g_strdup (nm_setting_802_1x_get_phase2_client_cert_path (s_8021X)); - return phase2_client_cert_str; + return cert_str; +} + +static char * +nmc_property_802_1X_get_phase2_client_cert_full (NMSetting *setting, NmcPropertyGetType get_type) +{ + return nmc_property_802_1X_get_phase2_client_cert (setting, get_type, TRUE); } static char * @@ -1096,35 +1122,57 @@ nmc_property_802_1X_get_password_raw (NMSetting *setting, NmcPropertyGetType get } static char * -nmc_property_802_1X_get_private_key (NMSetting *setting, NmcPropertyGetType get_type) +nmc_property_802_1X_get_private_key (NMSetting *setting, + NmcPropertyGetType get_type, + gboolean show_secrets) { NMSetting8021x *s_8021X = NM_SETTING_802_1X (setting); NMSetting8021xCKScheme scheme; - char *private_key_str = NULL; + char *key_str = NULL; scheme = nm_setting_802_1x_get_private_key_scheme (s_8021X); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) - private_key_str = bytes_to_string (nm_setting_802_1x_get_private_key_blob (s_8021X)); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) - private_key_str = g_strdup (nm_setting_802_1x_get_private_key_path (s_8021X)); + if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) { + if (show_secrets) + key_str = bytes_to_string (nm_setting_802_1x_get_private_key_blob (s_8021X)); + else + key_str = g_strdup (_("")); + } else if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) + key_str = g_strdup (nm_setting_802_1x_get_private_key_path (s_8021X)); + + return key_str; +} - return private_key_str; +static char * +nmc_property_802_1X_get_private_key_full (NMSetting *setting, NmcPropertyGetType get_type) +{ + return nmc_property_802_1X_get_private_key (setting, get_type, TRUE); } static char * -nmc_property_802_1X_get_phase2_private_key (NMSetting *setting, NmcPropertyGetType get_type) +nmc_property_802_1X_get_phase2_private_key (NMSetting *setting, + NmcPropertyGetType get_type, + gboolean show_secrets) { NMSetting8021x *s_8021X = NM_SETTING_802_1X (setting); NMSetting8021xCKScheme scheme; - char *phase2_private_key_str = NULL; + char *key_str = NULL; scheme = nm_setting_802_1x_get_phase2_private_key_scheme (s_8021X); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) - phase2_private_key_str = bytes_to_string (nm_setting_802_1x_get_phase2_private_key_blob (s_8021X)); - if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) - phase2_private_key_str = g_strdup (nm_setting_802_1x_get_phase2_private_key_path (s_8021X)); + if (scheme == NM_SETTING_802_1X_CK_SCHEME_BLOB) { + if (show_secrets) + key_str = bytes_to_string (nm_setting_802_1x_get_phase2_private_key_blob (s_8021X)); + else + key_str = g_strdup (_("")); + } else if (scheme == NM_SETTING_802_1X_CK_SCHEME_PATH) + key_str = g_strdup (nm_setting_802_1x_get_phase2_private_key_path (s_8021X)); - return phase2_private_key_str; + return key_str; +} + +static char * +nmc_property_802_1X_get_phase2_private_key_full (NMSetting *setting, NmcPropertyGetType get_type) +{ + return nmc_property_802_1X_get_phase2_private_key (setting, get_type, TRUE); } /* --- NM_SETTING_ADSL_SETTING_NAME property get functions --- */ @@ -1444,6 +1492,7 @@ DEFINE_GETTER (nmc_property_ipv4_get_method, NM_SETTING_IP_CONFIG_METHOD) DEFINE_GETTER (nmc_property_ipv4_get_dns, NM_SETTING_IP_CONFIG_DNS) DEFINE_GETTER (nmc_property_ipv4_get_dns_search, NM_SETTING_IP_CONFIG_DNS_SEARCH) DEFINE_GETTER_WITH_DEFAULT (nmc_property_ipv4_get_dns_options, NM_SETTING_IP_CONFIG_DNS_OPTIONS, !nm_setting_ip_config_has_dns_options ((NMSettingIPConfig *) setting)) +DEFINE_GETTER (nmc_property_ipv4_get_dns_priority, NM_SETTING_IP_CONFIG_DNS_PRIORITY) static char * nmc_property_ip_get_addresses (NMSetting *setting, NmcPropertyGetType get_type) @@ -1564,6 +1613,7 @@ DEFINE_GETTER (nmc_property_ipv6_get_method, NM_SETTING_IP_CONFIG_METHOD) DEFINE_GETTER (nmc_property_ipv6_get_dns, NM_SETTING_IP_CONFIG_DNS) DEFINE_GETTER (nmc_property_ipv6_get_dns_search, NM_SETTING_IP_CONFIG_DNS_SEARCH) DEFINE_GETTER_WITH_DEFAULT (nmc_property_ipv6_get_dns_options, NM_SETTING_IP_CONFIG_DNS_OPTIONS, !nm_setting_ip_config_has_dns_options ((NMSettingIPConfig *) setting)) +DEFINE_GETTER (nmc_property_ipv6_get_dns_priority, NM_SETTING_IP_CONFIG_DNS_PRIORITY) static char * nmc_property_ipv6_get_routes (NMSetting *setting, NmcPropertyGetType get_type) @@ -5709,7 +5759,7 @@ nmc_properties_init (void) NULL, NULL); nmc_add_prop_funcs (GLUE (802_1X, CLIENT_CERT), - nmc_property_802_1X_get_client_cert, + nmc_property_802_1X_get_client_cert_full, nmc_property_802_1X_set_client_cert, NULL, nmc_property_802_1X_describe_client_cert, @@ -5786,7 +5836,7 @@ nmc_properties_init (void) NULL, NULL); nmc_add_prop_funcs (GLUE (802_1X, PHASE2_CLIENT_CERT), - nmc_property_802_1X_get_phase2_client_cert, + nmc_property_802_1X_get_phase2_client_cert_full, nmc_property_802_1X_set_phase2_client_cert, NULL, nmc_property_802_1X_describe_phase2_client_cert, @@ -5821,7 +5871,7 @@ nmc_properties_init (void) NULL, NULL); nmc_add_prop_funcs (GLUE (802_1X, PRIVATE_KEY), - nmc_property_802_1X_get_private_key, + nmc_property_802_1X_get_private_key_full, nmc_property_802_1X_set_private_key, NULL, nmc_property_802_1X_describe_private_key, @@ -5842,7 +5892,7 @@ nmc_properties_init (void) NULL, NULL); nmc_add_prop_funcs (GLUE (802_1X, PHASE2_PRIVATE_KEY), - nmc_property_802_1X_get_phase2_private_key, + nmc_property_802_1X_get_phase2_private_key_full, nmc_property_802_1X_set_phase2_private_key, NULL, nmc_property_802_1X_describe_private_key, @@ -6452,6 +6502,13 @@ nmc_properties_init (void) NULL, NULL, NULL); + nmc_add_prop_funcs (GLUE_IP (4, DNS_PRIORITY), + nmc_property_ipv4_get_dns_priority, + nmc_property_set_int, + NULL, + NULL, + NULL, + NULL); nmc_add_prop_funcs (GLUE_IP (4, ADDRESSES), nmc_property_ip_get_addresses, nmc_property_ipv4_set_addresses, @@ -6580,6 +6637,13 @@ nmc_properties_init (void) NULL, NULL, NULL); + nmc_add_prop_funcs (GLUE_IP (6, DNS_PRIORITY), + nmc_property_ipv6_get_dns_priority, + nmc_property_set_int, + NULL, + NULL, + NULL, + NULL); nmc_add_prop_funcs (GLUE_IP (6, ADDRESSES), nmc_property_ip_get_addresses, nmc_property_ipv6_set_addresses, @@ -7999,7 +8063,7 @@ setting_802_1X_details (NMSetting *setting, NmCli *nmc, const char *one_prop, g set_val_str (arr, 7, nmc_property_802_1X_get_subject_match (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 8, nmc_property_802_1X_get_altsubject_matches (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 9, nmc_property_802_1X_get_domain_suffix_match (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 10, nmc_property_802_1X_get_client_cert (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 10, nmc_property_802_1X_get_client_cert (setting, NMC_PROPERTY_GET_PRETTY, secrets)); set_val_str (arr, 11, nmc_property_802_1X_get_phase1_peapver (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 12, nmc_property_802_1X_get_phase1_peaplabel (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 13, nmc_property_802_1X_get_phase1_fast_provisioning (setting, NMC_PROPERTY_GET_PRETTY)); @@ -8010,15 +8074,15 @@ setting_802_1X_details (NMSetting *setting, NmCli *nmc, const char *one_prop, g set_val_str (arr, 18, nmc_property_802_1X_get_phase2_subject_match (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 19, nmc_property_802_1X_get_phase2_altsubject_matches (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 20, nmc_property_802_1X_get_phase2_domain_suffix_match (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 21, nmc_property_802_1X_get_phase2_client_cert (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 21, nmc_property_802_1X_get_phase2_client_cert (setting, NMC_PROPERTY_GET_PRETTY, secrets)); set_val_str (arr, 22, GET_SECRET (secrets, setting, nmc_property_802_1X_get_password)); set_val_str (arr, 23, nmc_property_802_1X_get_password_flags (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 24, GET_SECRET (secrets, setting, nmc_property_802_1X_get_password_raw)); set_val_str (arr, 25, nmc_property_802_1X_get_password_raw_flags (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 26, nmc_property_802_1X_get_private_key (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 26, nmc_property_802_1X_get_private_key (setting, NMC_PROPERTY_GET_PRETTY, secrets)); set_val_str (arr, 27, GET_SECRET (secrets, setting, nmc_property_802_1X_get_private_key_password)); set_val_str (arr, 28, nmc_property_802_1X_get_private_key_password_flags (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 29, nmc_property_802_1X_get_phase2_private_key (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 29, nmc_property_802_1X_get_phase2_private_key (setting, NMC_PROPERTY_GET_PRETTY, secrets)); set_val_str (arr, 30, GET_SECRET (secrets, setting, nmc_property_802_1X_get_phase2_private_key_password)); set_val_str (arr, 31, nmc_property_802_1X_get_phase2_private_key_password_flags (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 32, GET_SECRET (secrets, setting, nmc_property_802_1X_get_pin)); @@ -8135,20 +8199,21 @@ setting_ip4_config_details (NMSetting *setting, NmCli *nmc, const char *one_pro set_val_str (arr, 2, nmc_property_ipv4_get_dns (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 3, nmc_property_ipv4_get_dns_search (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 4, nmc_property_ipv4_get_dns_options (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 5, nmc_property_ip_get_addresses (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 6, nmc_property_ipv4_get_gateway (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 7, nmc_property_ipv4_get_routes (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 8, nmc_property_ipv4_get_route_metric (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 9, nmc_property_ipv4_get_ignore_auto_routes (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 10, nmc_property_ipv4_get_ignore_auto_dns (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 11, nmc_property_ipv4_get_dhcp_client_id (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 12, nmc_property_ipv4_get_dhcp_timeout (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 13, nmc_property_ipv4_get_dhcp_send_hostname (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 14, nmc_property_ipv4_get_dhcp_hostname (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 15, nmc_property_ipv4_get_dhcp_fqdn (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 16, nmc_property_ipv4_get_never_default (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 17, nmc_property_ipv4_get_may_fail (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 18, nmc_property_ipv4_get_dad_timeout (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 5, nmc_property_ipv4_get_dns_priority (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 6, nmc_property_ip_get_addresses (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 7, nmc_property_ipv4_get_gateway (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 8, nmc_property_ipv4_get_routes (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 9, nmc_property_ipv4_get_route_metric (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 10, nmc_property_ipv4_get_ignore_auto_routes (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 11, nmc_property_ipv4_get_ignore_auto_dns (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 12, nmc_property_ipv4_get_dhcp_client_id (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 13, nmc_property_ipv4_get_dhcp_timeout (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 14, nmc_property_ipv4_get_dhcp_send_hostname (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 15, nmc_property_ipv4_get_dhcp_hostname (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 16, nmc_property_ipv4_get_dhcp_fqdn (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 17, nmc_property_ipv4_get_never_default (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 18, nmc_property_ipv4_get_may_fail (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 19, nmc_property_ipv4_get_dad_timeout (setting, NMC_PROPERTY_GET_PRETTY)); g_ptr_array_add (nmc->output_data, arr); print_data (nmc); /* Print all data */ @@ -8178,18 +8243,19 @@ setting_ip6_config_details (NMSetting *setting, NmCli *nmc, const char *one_pro set_val_str (arr, 2, nmc_property_ipv6_get_dns (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 3, nmc_property_ipv6_get_dns_search (setting, NMC_PROPERTY_GET_PRETTY)); set_val_str (arr, 4, nmc_property_ipv6_get_dns_options (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 5, nmc_property_ip_get_addresses (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 6, nmc_property_ipv6_get_gateway (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 7, nmc_property_ipv6_get_routes (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 8, nmc_property_ipv6_get_route_metric (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 9, nmc_property_ipv6_get_ignore_auto_routes (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 10, nmc_property_ipv6_get_ignore_auto_dns (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 11, nmc_property_ipv6_get_never_default (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 12, nmc_property_ipv6_get_may_fail (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 13, nmc_property_ipv6_get_ip6_privacy (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 14, nmc_property_ipv6_get_addr_gen_mode (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 15, nmc_property_ipv6_get_dhcp_send_hostname (setting, NMC_PROPERTY_GET_PRETTY)); - set_val_str (arr, 16, nmc_property_ipv6_get_dhcp_hostname (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 5, nmc_property_ipv6_get_dns_priority (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 6, nmc_property_ip_get_addresses (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 7, nmc_property_ipv6_get_gateway (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 8, nmc_property_ipv6_get_routes (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 9, nmc_property_ipv6_get_route_metric (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 10, nmc_property_ipv6_get_ignore_auto_routes (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 11, nmc_property_ipv6_get_ignore_auto_dns (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 12, nmc_property_ipv6_get_never_default (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 13, nmc_property_ipv6_get_may_fail (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 14, nmc_property_ipv6_get_ip6_privacy (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 15, nmc_property_ipv6_get_addr_gen_mode (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 16, nmc_property_ipv6_get_dhcp_send_hostname (setting, NMC_PROPERTY_GET_PRETTY)); + set_val_str (arr, 17, nmc_property_ipv6_get_dhcp_hostname (setting, NMC_PROPERTY_GET_PRETTY)); g_ptr_array_add (nmc->output_data, arr); print_data (nmc); /* Print all data */ diff --git a/clients/common/nm-vpn-helpers.c b/clients/common/nm-vpn-helpers.c index 880b6ecd..fe777ef5 100644 --- a/clients/common/nm-vpn-helpers.c +++ b/clients/common/nm-vpn-helpers.c @@ -36,30 +36,53 @@ static gboolean plugins_loaded; static GSList *plugins = NULL; NMVpnEditorPlugin * -nm_vpn_get_plugin_by_service (const char *service, GError **error) +nm_vpn_lookup_plugin (const char *name, const char *service, GError **error) { NMVpnEditorPlugin *plugin = NULL; NMVpnPluginInfo *plugin_info; - char *type = NULL; + gs_free_error GError *local = NULL; - g_return_val_if_fail (service != NULL, NULL); + g_return_val_if_fail (!service ^ !name, NULL); g_return_val_if_fail (error == NULL || *error == NULL, NULL); if (G_UNLIKELY (!plugins_loaded)) nm_vpn_get_plugins (); - if (!g_str_has_prefix (service, NM_DBUS_INTERFACE)) - service = type = g_strdup_printf ("%s.%s", NM_DBUS_INTERFACE, service); + if (service) + plugin_info = nm_vpn_plugin_info_list_find_by_service (plugins, service); + else + plugin_info = nm_vpn_plugin_info_list_find_by_name (plugins, name); + + if (!plugin_info) { + g_set_error (error, NM_VPN_PLUGIN_ERROR, NM_VPN_PLUGIN_ERROR_FAILED, + _("unknown VPN plugin \"%s\""), service ?: name); + return NULL; + } + plugin = nm_vpn_plugin_info_get_editor_plugin (plugin_info); + if (!plugin) + plugin = nm_vpn_plugin_info_load_editor_plugin (plugin_info, &local); + + if (!plugin) { + if ( !nm_vpn_plugin_info_get_plugin (plugin_info) + && nm_vpn_plugin_info_lookup_property (plugin_info, NM_VPN_PLUGIN_INFO_KF_GROUP_GNOME, "properties")) { + g_set_error (error, NM_VPN_PLUGIN_ERROR, NM_VPN_PLUGIN_ERROR_FAILED, + _("cannot cannot load legacy-only VPN plugin \"%s\" for \"%s\""), + nm_vpn_plugin_info_get_name (plugin_info), + nm_vpn_plugin_info_get_filename (plugin_info)); + } else if (g_error_matches (local, G_FILE_ERROR, G_FILE_ERROR_NOENT)) { + g_set_error (error, NM_VPN_PLUGIN_ERROR, NM_VPN_PLUGIN_ERROR_FAILED, + _("cannot load VPN plugin \"%s\" due to missing \"%s\". Missing client plugin?"), + nm_vpn_plugin_info_get_name (plugin_info), + nm_vpn_plugin_info_get_plugin (plugin_info)); + } else { + g_set_error (error, NM_VPN_PLUGIN_ERROR, NM_VPN_PLUGIN_ERROR_FAILED, + _("failed to load VPN plugin \"%s\": %s"), + nm_vpn_plugin_info_get_name (plugin_info), + local->message); + } + return NULL; + } - plugin_info = nm_vpn_plugin_info_list_find_by_service (plugins, service); - if (plugin_info) { - plugin = nm_vpn_plugin_info_get_editor_plugin (plugin_info); - if (!plugin) - plugin = nm_vpn_plugin_info_load_editor_plugin (plugin_info, error); - } else - g_set_error_literal (error, NM_VPN_PLUGIN_ERROR, NM_VPN_PLUGIN_ERROR_FAILED, - _("could not get VPN plugin info")); - g_free (type); return plugin; } @@ -73,6 +96,80 @@ nm_vpn_get_plugins (void) return plugins; } +static int +_strcmp_data (gconstpointer a, gconstpointer b, gpointer unused) +{ + return strcmp (a, b); +} + +const char ** +nm_vpn_get_plugin_names (gboolean only_available_plugins) +{ + GSList *p; + const char **list; + const char *known_names[] = { + "openvpn", + "vpnc", + "pptp", + "openconnect", + "openswan", + "libreswan", + "strongswan", + "ssh", + "l2tp", + "iodine", + "fortisslvpn", + }; + guint i, j, k; + + p = nm_vpn_get_plugins (); + list = g_new0 (const char *, g_slist_length (p) + G_N_ELEMENTS (known_names) + 1); + + i = 0; + for (i = 0; p; p = p->next) + list[i++] = nm_vpn_plugin_info_get_name (p->data); + if (!only_available_plugins) { + for (j = 0; j < G_N_ELEMENTS (known_names); j++) + list[i++] = known_names[j]; + } + + g_qsort_with_data (list, i, sizeof (gpointer), _strcmp_data, NULL); + + /* remove duplicates */ + for (k = 0, j = 1; j < i; j++) { + if (nm_streq (list[k], list[j])) + continue; + list[k++] = list[j]; + } + list[k++] = NULL; + + return list; +} + +const char * +nm_vpn_get_service_for_name (const char *name) +{ + NMVpnPluginInfo *plugin_info; + + g_return_val_if_fail (name, NULL); + + plugin_info = nm_vpn_plugin_info_list_find_by_name (nm_vpn_get_plugins (), name); + if (plugin_info) { + /* this only means we have a .name file (NMVpnPluginInfo). Possibly the + * NMVpnEditorPlugin is not loadable. */ + return nm_vpn_plugin_info_lookup_property (plugin_info, + NM_VPN_PLUGIN_INFO_KF_GROUP_CONNECTION, + "service"); + } + return NULL; +} + +char * +nm_vpn_get_service_for_name_default (const char *name) +{ + return g_strdup_printf ("%s.%s", NM_DBUS_INTERFACE, name); +} + gboolean nm_vpn_supports_ipv6 (NMConnection *connection) { @@ -85,10 +182,12 @@ nm_vpn_supports_ipv6 (NMConnection *connection) g_return_val_if_fail (s_vpn != NULL, FALSE); service_type = nm_setting_vpn_get_service_type (s_vpn); - g_return_val_if_fail (service_type != NULL, FALSE); + if (!service_type) + return FALSE; - plugin = nm_vpn_get_plugin_by_service (service_type, NULL); - g_return_val_if_fail (plugin != NULL, FALSE); + plugin = nm_vpn_lookup_plugin (NULL, service_type, NULL); + if (!plugin) + return FALSE; capabilities = nm_vpn_editor_plugin_get_capabilities (plugin); return NM_FLAGS_HAS (capabilities, NM_VPN_EDITOR_PLUGIN_CAPABILITY_IPV6); diff --git a/clients/common/nm-vpn-helpers.h b/clients/common/nm-vpn-helpers.h index 4f8d2194..79fc94e9 100644 --- a/clients/common/nm-vpn-helpers.h +++ b/clients/common/nm-vpn-helpers.h @@ -30,7 +30,12 @@ struct { GSList *nm_vpn_get_plugins (void); -NMVpnEditorPlugin *nm_vpn_get_plugin_by_service (const char *service, GError **error); +const char **nm_vpn_get_plugin_names (gboolean only_available_plugins); + +const char *nm_vpn_get_service_for_name (const char *name); +char * nm_vpn_get_service_for_name_default (const char *name); + +NMVpnEditorPlugin *nm_vpn_lookup_plugin (const char *name, const char *service, GError **error); gboolean nm_vpn_supports_ipv6 (NMConnection *connection); diff --git a/clients/tui/Makefile.in b/clients/tui/Makefile.in index 82b89bdd..d7773283 100644 --- a/clients/tui/Makefile.in +++ b/clients/tui/Makefile.in @@ -429,6 +429,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/clients/tui/newt/Makefile.in b/clients/tui/newt/Makefile.in index f1c579cb..3042089f 100644 --- a/clients/tui/newt/Makefile.in +++ b/clients/tui/newt/Makefile.in @@ -330,6 +330,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/clients/tui/nmtui-edit.c b/clients/tui/nmtui-edit.c index c7efd856..96c17245 100644 --- a/clients/tui/nmtui-edit.c +++ b/clients/tui/nmtui-edit.c @@ -184,7 +184,12 @@ create_connection (NmtNewtWidget *widget, gpointer list) connection = nm_editor_utils_create_connection (type, priv->master, nm_client); nmt_edit_connection (connection); g_object_unref (connection); +} +static void +create_connection_and_quit (NmtNewtWidget *widget, gpointer list) +{ + create_connection (widget, list); nmt_newt_form_quit (list); } @@ -203,7 +208,7 @@ nmt_add_connection_init (NmtAddConnection *form) listbox = nmt_newt_listbox_new (5, NMT_NEWT_LISTBOX_SCROLL); priv->listbox = NMT_NEWT_LISTBOX (listbox); - g_signal_connect (priv->listbox, "activated", G_CALLBACK (create_connection), form); + g_signal_connect (priv->listbox, "activated", G_CALLBACK (create_connection_and_quit), form); nmt_newt_grid_add (grid, listbox, 0, 1); nmt_newt_widget_set_padding (listbox, 0, 1, 0, 0); nmt_newt_grid_set_flags (grid, listbox, NMT_NEWT_GRID_EXPAND_X); @@ -223,7 +228,7 @@ nmt_add_connection_init (NmtAddConnection *form) NMT_NEWT_GRID_FILL_Y); button = g_object_ref_sink (nmt_newt_button_new (_("Create"))); - g_signal_connect (button, "clicked", G_CALLBACK (create_connection), form); + g_signal_connect (button, "clicked", G_CALLBACK (create_connection_and_quit), form); nmt_newt_grid_add (NMT_NEWT_GRID (buttons), button, 1, 0); nmt_newt_form_set_content (NMT_NEWT_FORM (form), NMT_NEWT_WIDGET (grid)); diff --git a/config.h.in b/config.h.in index baabb793..8f8fa7c0 100644 --- a/config.h.in +++ b/config.h.in @@ -149,6 +149,10 @@ /* The default value of the auth-polkit configuration option */ #undef NM_CONFIG_DEFAULT_AUTH_POLKIT +/* Default value for main.rc-manager setting + (--with-config-dns-rc-manager-default) */ +#undef NM_CONFIG_DEFAULT_DNS_RC_MANAGER + /* The default value of the logging.audit configuration option */ #undef NM_CONFIG_DEFAULT_LOGGING_AUDIT diff --git a/configure b/configure index 153d5c91..21340a82 100755 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.69 for NetworkManager 1.2.2. +# Generated by GNU Autoconf 2.69 for NetworkManager 1.2.4. # # Report bugs to . # @@ -591,8 +591,8 @@ MAKEFLAGS= # Identity of this package. PACKAGE_NAME='NetworkManager' PACKAGE_TARNAME='NetworkManager' -PACKAGE_VERSION='1.2.2' -PACKAGE_STRING='NetworkManager 1.2.2' +PACKAGE_VERSION='1.2.4' +PACKAGE_STRING='NetworkManager 1.2.4' PACKAGE_BUGREPORT='http://bugzilla.gnome.org/enter_bug.cgi?product=NetworkManager' PACKAGE_URL='' @@ -698,6 +698,7 @@ SYSTEM_CA_PATH DNSSEC_TRIGGER_SCRIPT DNSMASQ_PATH IPTABLES_PATH +NM_CONFIG_DEFAULT_DNS_RC_MANAGER with_netconfig with_resolvconf DHCPCD_PATH @@ -1060,6 +1061,7 @@ with_dhclient with_dhcpcd with_resolvconf with_netconfig +with_config_dns_rc_manager_default with_iptables with_dnsmasq with_dnssec_trigger @@ -1685,7 +1687,7 @@ if test "$ac_init_help" = "long"; then # Omit some internal or obsolete options to make the list less imposing. # This message is too long to be a string in the A/UX 3.1 sh. cat <<_ACEOF -\`configure' configures NetworkManager 1.2.2 to adapt to many kinds of systems. +\`configure' configures NetworkManager 1.2.4 to adapt to many kinds of systems. Usage: $0 [OPTION]... [VAR=VALUE]... @@ -1755,7 +1757,7 @@ fi if test -n "$ac_init_help"; then case $ac_init_help in - short | recursive ) echo "Configuration of NetworkManager 1.2.2:";; + short | recursive ) echo "Configuration of NetworkManager 1.2.4:";; esac cat <<\_ACEOF @@ -1883,6 +1885,8 @@ Optional Packages: --with-resolvconf=yes|no|path Enable resolvconf support --with-netconfig=yes|no Enable SUSE netconfig support + --with-config-dns-rc-manager-default=symlink|file|netconfig|resolvconf + Configure default value for main.rc-manager setting --with-iptables=/path/to/iptables path to iptables --with-dnsmasq=/path/to/dnsmasq @@ -2062,7 +2066,7 @@ fi test -n "$ac_init_help" && exit $ac_status if $ac_init_version; then cat <<\_ACEOF -NetworkManager configure 1.2.2 +NetworkManager configure 1.2.4 generated by GNU Autoconf 2.69 Copyright (C) 2012 Free Software Foundation, Inc. @@ -2789,7 +2793,7 @@ cat >config.log <<_ACEOF This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake. -It was created by NetworkManager $as_me 1.2.2, which was +It was created by NetworkManager $as_me 1.2.4, which was generated by GNU Autoconf 2.69. Invocation command line was $ $0 $@ @@ -3659,7 +3663,7 @@ fi # Define the identity of the package. PACKAGE='NetworkManager' - VERSION='1.2.2' + VERSION='1.2.4' cat >>confdefs.h <<_ACEOF @@ -17540,9 +17544,9 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu NM_MAJOR_VERSION=1 NM_MINOR_VERSION=2 -NM_MICRO_VERSION=2 -NM_VERSION=1.2.2 -NM_GIT_SHA=8f6d416768cf69932999b1fc2ab4231321761657 +NM_MICRO_VERSION=4 +NM_VERSION=1.2.4 +NM_GIT_SHA=54a84c6b3bd04123ee0831ae371d795ddd694cf9 @@ -24467,6 +24471,17 @@ if test "${with_netconfig+set}" = set; then : withval=$with_netconfig; fi + +# Check whether --with-config-dns-rc-manager-default was given. +if test "${with_config_dns_rc_manager_default+set}" = set; then : + withval=$with_config_dns_rc_manager_default; config_dns_rc_manager_default=$withval +fi + +if test "$config_dns_rc_manager_default" != symlink -a "$config_dns_rc_manager_default" != file -a "$config_dns_rc_manager_default" != netconfig -a "$config_dns_rc_manager_default" != resolvconf; then + { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unknown --with-config-dns-rc-manager-default=$config_dns_rc_manager_default setting." >&5 +$as_echo "$as_me: WARNING: Unknown --with-config-dns-rc-manager-default=$config_dns_rc_manager_default setting." >&2;} + config_dns_rc_manager_default= +fi # Use netconfig by default on SUSE if test -z "$with_netconfig"; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /etc/SuSE-release" >&5 @@ -24545,6 +24560,11 @@ fi done test -n "$with_resolvconf" || with_resolvconf="no" +fi +if test "$with_resolvconf" != "no"; then + if test -z "$config_dns_rc_manager_default"; then : + config_dns_rc_manager_default=resolvconf +fi fi if test "$with_netconfig" = "yes"; then for ac_prog in netconfig @@ -24594,6 +24614,14 @@ fi done test -n "$with_netconfig" || with_netconfig="no" +fi +if test "$with_netconfig" != "no"; then + if test -z "$config_dns_rc_manager_default"; then : + config_dns_rc_manager_default=netconfig +fi +fi +if test -z "$config_dns_rc_manager_default"; then : + config_dns_rc_manager_default=symlink fi # Define resolvconf and netconfig paths if test "$with_resolvconf" != "no"; then @@ -24611,6 +24639,13 @@ _ACEOF fi +cat >>confdefs.h <<_ACEOF +#define NM_CONFIG_DEFAULT_DNS_RC_MANAGER "$config_dns_rc_manager_default" +_ACEOF + +NM_CONFIG_DEFAULT_DNS_RC_MANAGER=$config_dns_rc_manager_default + + # iptables path # Check whether --with-iptables was given. @@ -27298,7 +27333,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 # report actual input values of CONFIG_FILES etc. instead of their # values after options handling. ac_log=" -This file was extended by NetworkManager $as_me 1.2.2, which was +This file was extended by NetworkManager $as_me 1.2.4, which was generated by GNU Autoconf 2.69. Invocation command line was CONFIG_FILES = $CONFIG_FILES @@ -27364,7 +27399,7 @@ _ACEOF cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" ac_cs_version="\\ -NetworkManager config.status 1.2.2 +NetworkManager config.status 1.2.4 configured by $0, generated by GNU Autoconf 2.69, with options \\"\$ac_cs_config\\" @@ -29743,6 +29778,7 @@ echo echo "Handlers for /etc/resolv.conf:" echo " resolvconf: ${with_resolvconf}" echo " netconfig: ${with_netconfig}" +echo " config-dns-rc-manager-default: ${config_dns_rc_manager_default}" echo echo "DHCP clients:" diff --git a/configure.ac b/configure.ac index 7bb3779e..4c56e14e 100644 --- a/configure.ac +++ b/configure.ac @@ -3,7 +3,7 @@ AC_PREREQ([2.63]) dnl The NM version number m4_define([nm_major_version], [1]) m4_define([nm_minor_version], [2]) -m4_define([nm_micro_version], [2]) +m4_define([nm_micro_version], [4]) m4_define([nm_version], [nm_major_version.nm_minor_version.nm_micro_version]) m4_define([nm_git_sha], [m4_esyscmd([ ( [ -d ./.git/ ] && [ "$(readlink -f ./.git/)" = "$(readlink -f "$(git rev-parse --git-dir 2>/dev/null)" 2>/dev/null)" ] && git rev-parse --verify -q HEAD 2>/dev/null ) || true ])]) @@ -763,6 +763,11 @@ fi # resolvconf and netconfig support AC_ARG_WITH(resolvconf, AS_HELP_STRING([--with-resolvconf=yes|no|path], [Enable resolvconf support])) AC_ARG_WITH(netconfig, AS_HELP_STRING([--with-netconfig=yes|no], [Enable SUSE netconfig support])) +AC_ARG_WITH(config-dns-rc-manager-default, AS_HELP_STRING([--with-config-dns-rc-manager-default=symlink|file|netconfig|resolvconf], [Configure default value for main.rc-manager setting]), [config_dns_rc_manager_default=$withval]) +if test "$config_dns_rc_manager_default" != symlink -a "$config_dns_rc_manager_default" != file -a "$config_dns_rc_manager_default" != netconfig -a "$config_dns_rc_manager_default" != resolvconf; then + AC_MSG_WARN([Unknown --with-config-dns-rc-manager-default=$config_dns_rc_manager_default setting.]) + config_dns_rc_manager_default= +fi # Use netconfig by default on SUSE AS_IF([test -z "$with_netconfig"], AC_CHECK_FILE(/etc/SuSE-release, with_netconfig=yes)) # Otherwise default to "no" @@ -772,9 +777,16 @@ AS_IF([test -z "$with_netconfig"], with_netconfig=no) if test "$with_resolvconf" = "yes"; then AC_PATH_PROGS(with_resolvconf, resolvconf, no, /sbin:/usr/sbin:/usr/local/sbin) fi +if test "$with_resolvconf" != "no"; then + AS_IF([test -z "$config_dns_rc_manager_default"], config_dns_rc_manager_default=resolvconf) +fi if test "$with_netconfig" = "yes"; then AC_PATH_PROGS(with_netconfig, netconfig, no, /sbin:/usr/sbin:/usr/local/sbin) fi +if test "$with_netconfig" != "no"; then + AS_IF([test -z "$config_dns_rc_manager_default"], config_dns_rc_manager_default=netconfig) +fi +AS_IF([test -z "$config_dns_rc_manager_default"], config_dns_rc_manager_default=symlink) # Define resolvconf and netconfig paths if test "$with_resolvconf" != "no"; then AC_DEFINE_UNQUOTED(RESOLVCONF_PATH, "$with_resolvconf", [Path to resolvconf]) @@ -782,6 +794,8 @@ fi if test "$with_netconfig" != "no"; then AC_DEFINE_UNQUOTED(NETCONFIG_PATH, "$with_netconfig", [Path to netconfig]) fi +AC_DEFINE_UNQUOTED(NM_CONFIG_DEFAULT_DNS_RC_MANAGER, "$config_dns_rc_manager_default", [Default value for main.rc-manager setting (--with-config-dns-rc-manager-default)]) +AC_SUBST(NM_CONFIG_DEFAULT_DNS_RC_MANAGER, $config_dns_rc_manager_default) # iptables path AC_ARG_WITH(iptables, AS_HELP_STRING([--with-iptables=/path/to/iptables], [path to iptables])) @@ -1164,6 +1178,7 @@ echo echo "Handlers for /etc/resolv.conf:" echo " resolvconf: ${with_resolvconf}" echo " netconfig: ${with_netconfig}" +echo " config-dns-rc-manager-default: ${config_dns_rc_manager_default}" echo echo "DHCP clients:" diff --git a/data/Makefile.in b/data/Makefile.in index c50d11f5..9bdf8fbb 100644 --- a/data/Makefile.in +++ b/data/Makefile.in @@ -297,6 +297,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/data/NetworkManager-wait-online-systemd-pre200.service.in b/data/NetworkManager-wait-online-systemd-pre200.service.in index d145a79f..55e4508c 100644 --- a/data/NetworkManager-wait-online-systemd-pre200.service.in +++ b/data/NetworkManager-wait-online-systemd-pre200.service.in @@ -1,5 +1,6 @@ [Unit] Description=Network Manager Wait Online +Documentation=man:nm-online(1) Requisite=NetworkManager.service After=NetworkManager.service Wants=network.target @@ -8,6 +9,7 @@ Before=network.target [Service] Type=oneshot ExecStart=@bindir@/nm-online -s -q --timeout=30 +RemainAfterExit=yes [Install] WantedBy=network.target diff --git a/data/NetworkManager-wait-online.service.in b/data/NetworkManager-wait-online.service.in index 8c4fa678..1753d203 100644 --- a/data/NetworkManager-wait-online.service.in +++ b/data/NetworkManager-wait-online.service.in @@ -1,5 +1,6 @@ [Unit] Description=Network Manager Wait Online +Documentation=man:nm-online(1) Requisite=NetworkManager.service After=NetworkManager.service Before=network-online.target @@ -7,6 +8,7 @@ Before=network-online.target [Service] Type=oneshot ExecStart=@bindir@/nm-online -s -q --timeout=30 +RemainAfterExit=yes [Install] WantedBy=network-online.target diff --git a/data/NetworkManager.service.in b/data/NetworkManager.service.in index 7946ac18..95128a68 100644 --- a/data/NetworkManager.service.in +++ b/data/NetworkManager.service.in @@ -1,5 +1,6 @@ [Unit] Description=Network Manager +Documentation=man:NetworkManager(8) Wants=network.target After=network-pre.target dbus.service Before=network.target @DISTRO_NETWORK_SERVICE@ @@ -7,6 +8,7 @@ Before=network.target @DISTRO_NETWORK_SERVICE@ [Service] Type=dbus BusName=org.freedesktop.NetworkManager +#ExecReload=/usr/bin/dbus-send --print-reply --system --type=method_call --dest=org.freedesktop.NetworkManager /org/freedesktop/NetworkManager org.freedesktop.NetworkManager.Reload uint32:0 ExecReload=/bin/kill -HUP $MAINPID ExecStart=@sbindir@/NetworkManager --no-daemon Restart=on-failure diff --git a/docs/Makefile.in b/docs/Makefile.in index 46116645..a91f4190 100644 --- a/docs/Makefile.in +++ b/docs/Makefile.in @@ -328,6 +328,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/docs/api/Makefile.in b/docs/api/Makefile.in index 7407f4fa..bc388a41 100644 --- a/docs/api/Makefile.in +++ b/docs/api/Makefile.in @@ -274,6 +274,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/docs/api/html/NetworkManager.conf.html b/docs/api/html/NetworkManager.conf.html index 0c05211a..828776ff 100644 --- a/docs/api/html/NetworkManager.conf.html +++ b/docs/api/html/NetworkManager.conf.html @@ -64,6 +64,10 @@ This file is not intended to be modified by the user, but it is read last and can shadow user configuration from NetworkManager.conf.

+

+ Certain settings from the configuration can be reloaded at runtime either by sending SIGHUP signal or via + D-Bus' Reload call. +

File Format

@@ -296,7 +300,8 @@ no-auto-default=* configuration with DNSSEC support. The /etc/resolv.conf will be managed by dnssec-trigger daemon.

none: NetworkManager will not - modify resolv.conf.

+ modify resolv.conf. This implies rc-manager + unmanaged

@@ -304,17 +309,25 @@ no-auto-default=*

Set the resolv.conf management mode. The default value depends on how NetworkManager - was built. Regardless of this setting, NetworkManager will + was built, whereas this version of NetworkManager was build with + a default of "symlink". + Regardless of this setting, NetworkManager will always write resolv.conf to its runtime state directory.

-

none: NetworkManager will symlink +

symlink: NetworkManager will symlink /etc/resolv.conf to its private resolv.conf file in the runtime state directory.

file: NetworkManager will write - /etc/resolv.conf as file.

+ /etc/resolv.conf as file. If it finds + a symlink, it will follow the symlink and update the target + instead.

resolvconf: NetworkManager will run resolvconf to update the DNS configuration.

netconfig: NetworkManager will run netconfig to update the DNS configuration.

+

unmanaged: don't touch + resolv.conf.

+

none: deprecated alias for + symlink.

@@ -363,7 +376,7 @@ no-auto-default=*

path

The location where keyfiles are read and stored. - This defaults to "/etc/NetworkManager/conf.d". + This defaults to "${prefix}/etc/NetworkManager/conf.d".

@@ -649,8 +662,10 @@ ipv6.ip6-privacy=1 considered even if the property in question is not present. In the example above, if [connection-wifi-wlan0] would have stop-match set to yes, - its ipv6.ip6-privacy value would be - unspecified. + the device wlan0 would have ipv6.ip6-privacy + property unspecified. That is, the search for the property would not continue + in the connection sections [connection-wifi-other] + or [connection].

diff --git a/docs/api/html/NetworkManager.devhelp2 b/docs/api/html/NetworkManager.devhelp2 index 850ff2e2..c0e6a7af 100644 --- a/docs/api/html/NetworkManager.devhelp2 +++ b/docs/api/html/NetworkManager.devhelp2 @@ -61,6 +61,7 @@ + @@ -317,6 +318,7 @@ + @@ -328,6 +330,7 @@ + diff --git a/docs/api/html/NetworkManager.html b/docs/api/html/NetworkManager.html index 835a7e66..5467a3a8 100644 --- a/docs/api/html/NetworkManager.html +++ b/docs/api/html/NetworkManager.html @@ -436,26 +436,47 @@ The signal causes a reload of NetworkManager's configuration. Note that not all configuration parameters can be changed at runtime and therefore some changes may be applied only after - the next restart of the daemon. The signal also forces a - rewrite of DNS configuration. + the next restart of the daemon. + A SIGHUP also involves further reloading actions, like doing + a DNS update and restarting the DNS plugin. The latter can be + useful for example when using the dnsmasq plugin and changing + its configuration in /etc/NetworkManager/dnsmasq.d. However, + it also means this will shortly interrupt name resolution. + In the future, there may be further actions added. + A SIGHUP means to update NetworkManager configuration and reload + everything that is supported. Note that this does not reload + connections from disk. For that there is a D-Bus API and + nmcli's reload action

SIGUSR1

- The signal forces a rewrite of DNS configuration. + The signal forces a rewrite of DNS configuration. Contrary to + SIGHUP, this does not restart the DNS plugin and will not interrupt + name resolution. + In the future, further actions may be added. A SIGUSR1 + means to write out data like resolv.conf, or refresh a cache. + It is a subset of what is done for SIGHUP without reloading + configuration from disk.

SIGUSR2

- The signal has no effect at the moment. + The signal has no effect at the moment but is reserved for future + use.

+

+ An alternative to a signal to reload configuration is the Reload D-Bus call. + It allows for more fine-grained selection of what to reload, it only returns + after the reload is complete, and it is guarded by PolicyKit. +

DEBUGGING

diff --git a/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP4Config.html b/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP4Config.html index fd291730..5f2615cf 100644 --- a/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP4Config.html +++ b/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP4Config.html @@ -51,6 +51,7 @@ Domains readable as Searches readable as DnsOptions readable as +DnsPriority readable i WinsServers readable au
@@ -173,6 +174,15 @@ DnsOptions readable as
+

The "DnsPriority" property

+
+DnsPriority  readable   i
+
+

The relative priority of DNS servers. +

+
+
+

The "WinsServers" property

 WinsServers  readable   au
diff --git a/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP6Config.html b/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP6Config.html
index 9bd4562a..65995603 100644
--- a/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP6Config.html
+++ b/docs/api/html/gdbus-org.freedesktop.NetworkManager.IP6Config.html
@@ -51,6 +51,7 @@
 Domains      readable   as
 Searches     readable   as
 DnsOptions   readable   as
+DnsPriority  readable   i
 
@@ -165,6 +166,15 @@ DnsOptions readable as resolv.conf(5) manual page for the list of supported options.

+
+
+

The "DnsPriority" property

+
+DnsPriority  readable   i
+
+

The relative priority of DNS servers. +

+
@@ -3267,7 +3310,7 @@ nm_setting_ip_config_remove_route_by_value nm_setting_ip_config_clear_routes (NMSettingIPConfig *setting);

Removes all configured routes.

-

Parameters

+

Parameters

@@ -3290,7 +3333,7 @@ nm_setting_ip_config_get_route_metric (“route-metric” property.

-

Parameters

+

Parameters

@@ -3305,7 +3348,7 @@ property.

-

Returns

+

Returns

the route metric that is used for routes that don't explicitly specify a metric. See “route-metric” for more details.

@@ -3319,7 +3362,7 @@ nm_setting_ip_config_get_ignore_auto_routes

Returns the value contained in the “ignore-auto-routes” property.

-

Parameters

+

Parameters

@@ -3334,7 +3377,7 @@ property.

-

Returns

+

Returns

TRUE if automatically configured (ie via DHCP) routes should be ignored.

@@ -3348,7 +3391,7 @@ nm_setting_ip_config_get_ignore_auto_dns

Returns the value contained in the “ignore-auto-dns” property.

-

Parameters

+

Parameters

@@ -3363,7 +3406,7 @@ property.

-

Returns

+

Returns

TRUE if automatically configured (ie via DHCP) DNS information should be ignored.

@@ -3377,7 +3420,7 @@ nm_setting_ip_config_get_dhcp_hostname

Returns the value contained in the “dhcp-hostname” property.

-

Parameters

+

Parameters

@@ -3392,7 +3435,7 @@ property.

-

Returns

+

Returns

the configured hostname to send to the DHCP server

@@ -3405,7 +3448,7 @@ nm_setting_ip_config_get_dhcp_send_hostname

Returns the value contained in the “dhcp-send-hostname” property.

-

Parameters

+

Parameters

@@ -3420,7 +3463,7 @@ property.

-

Returns

+

Returns

TRUE if NetworkManager should send the machine hostname to the DHCP server when requesting addresses to allow the server to automatically update DNS information for this machine.

@@ -3435,7 +3478,7 @@ nm_setting_ip_config_get_never_default

Returns the value contained in the “never-default” property.

-

Parameters

+

Parameters

@@ -3450,7 +3493,7 @@ property.

-

Returns

+

Returns

TRUE if this connection should never be the default connection

@@ -3463,7 +3506,7 @@ nm_setting_ip_config_get_may_fail (Returns the value contained in the “may-fail” property.

-

Parameters

+

Parameters

@@ -3478,7 +3521,7 @@ property.

-

Returns

+

Returns

TRUE if this connection doesn't require this type of IP addressing to complete for the connection to succeed.

@@ -3489,7 +3532,7 @@ addressing to complete for the connection to succeed.

gint
 nm_setting_ip_config_get_dad_timeout (NMSettingIPConfig *setting);
-

Parameters

+

Parameters

@@ -3504,7 +3547,7 @@ nm_setting_ip_config_get_dad_timeout ( -

Returns

+

Returns

the “dad-timeout” property.

Since: 1.2

@@ -3517,7 +3560,7 @@ nm_setting_ip_config_get_dhcp_timeout (“dhcp-timeout” property.

-

Parameters

+

Parameters

@@ -3532,7 +3575,7 @@ property.

-

Returns

+

Returns

the configured DHCP timeout in seconds. 0 = default for the particular kind of device.

@@ -3572,6 +3615,12 @@ the particular kind of device.


+

NM_SETTING_IP_CONFIG_DNS_PRIORITY

+
#define NM_SETTING_IP_CONFIG_DNS_PRIORITY       "dns-priority"
+
+
+
+

NM_SETTING_IP_CONFIG_ADDRESSES

#define NM_SETTING_IP_CONFIG_ADDRESSES          "addresses"
 
@@ -3814,6 +3863,26 @@ distinct from an empty list of properties.


+

The “dns-priority” property

+
  “dns-priority”             gint
+

DNS priority.

+

The relative priority to be used when determining the order of DNS +servers in resolv.conf. A lower value means that servers will be on top +of the file. Zero selects the default value, which is 50 for VPNs and +100 for other connections. When multiple devices have configurations +with the same priority, the one with an active default route will be +preferred. Note that when using dns=dnsmasq the order is meaningless +since dnsmasq forwards queries to all known servers at the same time.

+

Negative values have the special effect of excluding other configurations +with a greater priority value; so in presence of at least a negative +priority, only DNS servers from configurations with the lowest priority +value will be used.

+

Flags: Read / Write / Construct

+

Default value: 0

+

Since: 1.2.4

+
+
+

The “dns-search” property

  “dns-search”               GStrv

Array of DNS search domains.

diff --git a/docs/libnm/html/NMSettingMacvlan.html b/docs/libnm/html/NMSettingMacvlan.html index d5d1a207..d924b0f9 100644 --- a/docs/libnm/html/NMSettingMacvlan.html +++ b/docs/libnm/html/NMSettingMacvlan.html @@ -157,7 +157,7 @@

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMSettingMacvlanMode
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMSettingSerial.html b/docs/libnm/html/NMSettingSerial.html
index 07f82316..b31f0715 100644
--- a/docs/libnm/html/NMSettingSerial.html
+++ b/docs/libnm/html/NMSettingSerial.html
@@ -175,7 +175,7 @@ serial communications

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMSettingSerialParity
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMSettingTun.html b/docs/libnm/html/NMSettingTun.html
index 9a7a9fc5..41837ea7 100644
--- a/docs/libnm/html/NMSettingTun.html
+++ b/docs/libnm/html/NMSettingTun.html
@@ -191,7 +191,7 @@
 

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMSettingTunMode
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMSettingVlan.html b/docs/libnm/html/NMSettingVlan.html
index 61e4bf45..25807d63 100644
--- a/docs/libnm/html/NMSettingVlan.html
+++ b/docs/libnm/html/NMSettingVlan.html
@@ -230,9 +230,9 @@
 

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMVlanPriorityMap
-    GFlags
+    GFlags
     ╰── NMVlanFlags
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMSettingWired.html b/docs/libnm/html/NMSettingWired.html
index cdb857f4..568b9d5e 100644
--- a/docs/libnm/html/NMSettingWired.html
+++ b/docs/libnm/html/NMSettingWired.html
@@ -394,7 +394,7 @@
 

Object Hierarchy

-
    GFlags
+
    GFlags
     ╰── NMSettingWiredWakeOnLan
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMSettingWireless.html b/docs/libnm/html/NMSettingWireless.html
index b9cb002e..a58e847c 100644
--- a/docs/libnm/html/NMSettingWireless.html
+++ b/docs/libnm/html/NMSettingWireless.html
@@ -426,7 +426,7 @@
 

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMSettingWirelessPowersave
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMSettingWirelessSecurity.html b/docs/libnm/html/NMSettingWirelessSecurity.html
index 9e5098f2..b8e8f37f 100644
--- a/docs/libnm/html/NMSettingWirelessSecurity.html
+++ b/docs/libnm/html/NMSettingWirelessSecurity.html
@@ -483,7 +483,7 @@ use WEP, LEAP, WPA or WPA2/RSN security

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMWepKeyType
     GObject
     ╰── NMSetting
diff --git a/docs/libnm/html/NMVpnEditorPlugin.html b/docs/libnm/html/NMVpnEditorPlugin.html
index 1e807951..d49d5fea 100644
--- a/docs/libnm/html/NMVpnEditorPlugin.html
+++ b/docs/libnm/html/NMVpnEditorPlugin.html
@@ -192,9 +192,9 @@
 

Object Hierarchy

-
    GFlags
+
    GFlags
     ╰── NMVpnEditorPluginCapability
-    GInterface
+    GInterface
     ├── NMVpnEditor
     ╰── NMVpnEditorPlugin
 
diff --git a/docs/libnm/html/api-index-full.html b/docs/libnm/html/api-index-full.html index 277b9132..5450ce1f 100644 --- a/docs/libnm/html/api-index-full.html +++ b/docs/libnm/html/api-index-full.html @@ -415,7 +415,7 @@
-NM_AVAILABLE_IN_1_4, macro in nm-version +NM_AVAILABLE_IN_1_2_4, macro in nm-version

B

@@ -1470,14 +1470,6 @@
-NM_DEPRECATED_IN_1_4, macro in nm-version -
-
-
-NM_DEPRECATED_IN_1_4_FOR, macro in nm-version -
-
-
NMDevice, struct in nm-types
@@ -4300,6 +4292,10 @@
+NMSettingIPConfig:dns-priority, object property in NMSettingIPConfig +
+
+
NMSettingIPConfig:dns-search, object property in NMSettingIPConfig
@@ -6568,6 +6564,10 @@
+NM_SETTING_IP_CONFIG_DNS_PRIORITY, macro in NMSettingIPConfig +
+
+
NM_SETTING_IP_CONFIG_DNS_SEARCH, macro in NMSettingIPConfig
@@ -6604,6 +6604,10 @@
+nm_setting_ip_config_get_dns_priority, function in NMSettingIPConfig +
+
+
nm_setting_ip_config_get_dns_search, function in NMSettingIPConfig
diff --git a/docs/libnm/html/index.html b/docs/libnm/html/index.html index eea02301..8794d373 100644 --- a/docs/libnm/html/index.html +++ b/docs/libnm/html/index.html @@ -15,7 +15,7 @@

- for libnm 1.2.2 + for libnm 1.2.4 The latest version of this documentation can be found on-line at https://developer.gnome.org/libnm/stable/. diff --git a/docs/libnm/html/index.sgml b/docs/libnm/html/index.sgml index e2a6f09d..82b34062 100644 --- a/docs/libnm/html/index.sgml +++ b/docs/libnm/html/index.sgml @@ -104,6 +104,8 @@ + + @@ -264,6 +266,7 @@ + @@ -1410,6 +1413,7 @@ + @@ -1438,6 +1442,7 @@ + @@ -1474,6 +1479,7 @@ + @@ -3068,7 +3074,6 @@ - @@ -3076,8 +3081,7 @@ - - + diff --git a/docs/libnm/html/libnm-nm-dbus-interface.html b/docs/libnm/html/libnm-nm-dbus-interface.html index 2dcd7309..cafcbd4b 100644 --- a/docs/libnm/html/libnm-nm-dbus-interface.html +++ b/docs/libnm/html/libnm-nm-dbus-interface.html @@ -353,7 +353,7 @@

Object Hierarchy

-
    GEnum
+
    GEnum
     ├── NM80211Mode
     ├── NMActiveConnectionState
     ├── NMConnectivityState
@@ -364,7 +364,7 @@
     ├── NMMetered
     ├── NMState
     ╰── NMWimaxNspNetworkType
-    GFlags
+    GFlags
     ├── NM80211ApFlags
     ├── NM80211ApSecurityFlags
     ├── NMBluetoothCapabilities
diff --git a/docs/libnm/html/libnm-nm-errors.html b/docs/libnm/html/libnm-nm-errors.html
index f2720bfe..13444902 100644
--- a/docs/libnm/html/libnm-nm-errors.html
+++ b/docs/libnm/html/libnm-nm-errors.html
@@ -184,7 +184,7 @@
 

Object Hierarchy

-
    GEnum
+
    GEnum
     ├── NMAgentManagerError
     ├── NMConnectionError
     ├── NMCryptoError
@@ -714,6 +714,13 @@ errors in that namespace.

  + +

NM_MANAGER_ERROR_INVALID_ARGUMENTS

+ +

Invalid arguments for D-Bus request

+ +  +
diff --git a/docs/libnm/html/libnm-nm-utils.html b/docs/libnm/html/libnm-nm-utils.html index 65300023..1ae50f34 100644 --- a/docs/libnm/html/libnm-nm-utils.html +++ b/docs/libnm/html/libnm-nm-utils.html @@ -551,7 +551,7 @@

Object Hierarchy

-
    GEnum
+
    GEnum
     ╰── NMUtilsSecurityType
 
diff --git a/docs/libnm/html/libnm-nm-version.html b/docs/libnm/html/libnm-nm-version.html index 5e1c3977..4af37c3c 100644 --- a/docs/libnm/html/libnm-nm-version.html +++ b/docs/libnm/html/libnm-nm-version.html @@ -65,12 +65,6 @@ NM_DEPRECATED_IN_1_2_FOR() - -#define - -NM_DEPRECATED_IN_1_4_FOR() - - @@ -108,11 +102,7 @@ #define -NM_DEPRECATED_IN_1_4 - - -#define -NM_AVAILABLE_IN_1_4 +NM_AVAILABLE_IN_1_2_4 @@ -151,12 +141,6 @@
# define NM_DEPRECATED_IN_1_2_FOR(f)    G_DEPRECATED_FOR(f)
 
-
-
-

NM_DEPRECATED_IN_1_4_FOR()

-
# define NM_DEPRECATED_IN_1_4_FOR(f)    G_DEPRECATED_FOR(f)
-
-

Types and Values

@@ -196,14 +180,8 @@

-

NM_DEPRECATED_IN_1_4

-
# define NM_DEPRECATED_IN_1_4           G_DEPRECATED
-
-
-
-
-

NM_AVAILABLE_IN_1_4

-
# define NM_AVAILABLE_IN_1_4            G_UNAVAILABLE(1,4)
+

NM_AVAILABLE_IN_1_2_4

+
# define NM_AVAILABLE_IN_1_2_4          G_UNAVAILABLE(1.2,4)
 
diff --git a/docs/libnm/html/libnm-nm-vpn-dbus-interface.html b/docs/libnm/html/libnm-nm-vpn-dbus-interface.html index d5be4bee..299f1d09 100644 --- a/docs/libnm/html/libnm-nm-vpn-dbus-interface.html +++ b/docs/libnm/html/libnm-nm-vpn-dbus-interface.html @@ -293,7 +293,7 @@

Object Hierarchy

-
    GEnum
+
    GEnum
     ├── NMVpnConnectionState
     ├── NMVpnConnectionStateReason
     ├── NMVpnPluginFailure
diff --git a/docs/libnm/html/libnm.devhelp2 b/docs/libnm/html/libnm.devhelp2
index e4b37f3c..5358ef52 100644
--- a/docs/libnm/html/libnm.devhelp2
+++ b/docs/libnm/html/libnm.devhelp2
@@ -979,6 +979,7 @@
     
     
     
+    
     
     
     
@@ -1006,6 +1007,7 @@
     
     
     
+    
     
     
     
@@ -1041,6 +1043,7 @@
     
     
     
+    
     
     
     
@@ -2168,15 +2171,13 @@
     
     
     
-    
     
     
     
     
     
     
-    
-    
+    
     
     
     
@@ -2269,6 +2270,8 @@
     
     
     
+    
+    
     
     
     
@@ -2318,6 +2321,7 @@
     
     
     
+    
     
     
     
diff --git a/docs/libnm/html/object-tree.html b/docs/libnm/html/object-tree.html
index ea853287..147fbcc2 100644
--- a/docs/libnm/html/object-tree.html
+++ b/docs/libnm/html/object-tree.html
@@ -85,11 +85,11 @@
     ├── NMClient
     ├── NMSecretAgentOld
     ╰── NMSimpleConnection
-    GInterface
+    GInterface
     ├── NMConnection
     ├── NMVpnEditor
     ╰── NMVpnEditorPlugin
-    GFlags
+    GFlags
     ├── NM80211ApFlags
     ├── NM80211ApSecurityFlags
     ├── NMBluetoothCapabilities
@@ -104,7 +104,7 @@
     ├── NMSettingWiredWakeOnLan
     ├── NMVlanFlags
     ╰── NMVpnEditorPluginCapability
-    GEnum
+    GEnum
     ├── NMAgentManagerError
     ├── NMConnectionError
     ├── NMDeviceError
@@ -146,7 +146,7 @@
     ├── NMVpnServiceState
     ├── NMWepKeyType
     ╰── NMWimaxNspNetworkType
-    GBoxed
+    GBoxed
     ├── NMIPAddress
     ├── NMIPRoute
     ╰── NMLldpNeighbor
diff --git a/docs/libnm/libnm-sections.txt b/docs/libnm/libnm-sections.txt
index 4d7b5f25..adb1dc9f 100644
--- a/docs/libnm/libnm-sections.txt
+++ b/docs/libnm/libnm-sections.txt
@@ -1804,6 +1804,7 @@ NM_SETTING_IP_CONFIG_METHOD
 NM_SETTING_IP_CONFIG_DNS
 NM_SETTING_IP_CONFIG_DNS_SEARCH
 NM_SETTING_IP_CONFIG_DNS_OPTIONS
+NM_SETTING_IP_CONFIG_DNS_PRIORITY
 NM_SETTING_IP_CONFIG_ADDRESSES
 NM_SETTING_IP_CONFIG_GATEWAY
 NM_SETTING_IP_CONFIG_ROUTES
@@ -1853,6 +1854,7 @@ nm_setting_ip_config_add_dns_option
 nm_setting_ip_config_remove_dns_option
 nm_setting_ip_config_remove_dns_option_by_value
 nm_setting_ip_config_clear_dns_options
+nm_setting_ip_config_get_dns_priority
 nm_setting_ip_config_get_num_addresses
 nm_setting_ip_config_get_address
 nm_setting_ip_config_add_address
@@ -2664,9 +2666,7 @@ NM_AVAILABLE_IN_1_0
 NM_DEPRECATED_IN_1_2
 NM_DEPRECATED_IN_1_2_FOR
 NM_AVAILABLE_IN_1_2
-NM_DEPRECATED_IN_1_4
-NM_DEPRECATED_IN_1_4_FOR
-NM_AVAILABLE_IN_1_4
+NM_AVAILABLE_IN_1_2_4
 
 
 
diff --git a/docs/libnm/version.xml b/docs/libnm/version.xml index 23aa8390..e8ea05db 100644 --- a/docs/libnm/version.xml +++ b/docs/libnm/version.xml @@ -1 +1 @@ -1.2.2 +1.2.4 diff --git a/examples/C/Makefile.in b/examples/C/Makefile.in index 77e47215..4f2a6a97 100644 --- a/examples/C/Makefile.in +++ b/examples/C/Makefile.in @@ -325,6 +325,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/C/glib/Makefile.in b/examples/C/glib/Makefile.in index 782318fc..4c6abd2b 100644 --- a/examples/C/glib/Makefile.in +++ b/examples/C/glib/Makefile.in @@ -363,6 +363,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/C/qt/Makefile.in b/examples/C/qt/Makefile.in index 04634ccf..6555d0d0 100644 --- a/examples/C/qt/Makefile.in +++ b/examples/C/qt/Makefile.in @@ -335,6 +335,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/Makefile.in b/examples/Makefile.in index 352ddb15..bc4acdd6 100644 --- a/examples/Makefile.in +++ b/examples/Makefile.in @@ -324,6 +324,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/dispatcher/Makefile.in b/examples/dispatcher/Makefile.in index c28c3dd1..af6fb984 100644 --- a/examples/dispatcher/Makefile.in +++ b/examples/dispatcher/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/lua/Makefile.in b/examples/lua/Makefile.in index 625155ed..9ebe048d 100644 --- a/examples/lua/Makefile.in +++ b/examples/lua/Makefile.in @@ -324,6 +324,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/lua/lgi/Makefile.in b/examples/lua/lgi/Makefile.in index 3025d55b..646192ed 100644 --- a/examples/lua/lgi/Makefile.in +++ b/examples/lua/lgi/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/python/Makefile.in b/examples/python/Makefile.in index e5552ae8..9f39ae63 100644 --- a/examples/python/Makefile.in +++ b/examples/python/Makefile.in @@ -324,6 +324,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/python/dbus/Makefile.in b/examples/python/dbus/Makefile.in index 1fcfd9cd..70a0d583 100644 --- a/examples/python/dbus/Makefile.in +++ b/examples/python/dbus/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/python/gi/Makefile.in b/examples/python/gi/Makefile.in index 972092ad..362ecee5 100644 --- a/examples/python/gi/Makefile.in +++ b/examples/python/gi/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/python/python-networkmanager/Makefile.in b/examples/python/python-networkmanager/Makefile.in index 43c752be..e0d0bd37 100644 --- a/examples/python/python-networkmanager/Makefile.in +++ b/examples/python/python-networkmanager/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/ruby/Makefile.in b/examples/ruby/Makefile.in index aaa6818b..305a48eb 100644 --- a/examples/ruby/Makefile.in +++ b/examples/ruby/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/examples/shell/Makefile.in b/examples/shell/Makefile.in index dd9e966d..7afaeab8 100644 --- a/examples/shell/Makefile.in +++ b/examples/shell/Makefile.in @@ -264,6 +264,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/introspection/Makefile.in b/introspection/Makefile.in index c6f4ba26..3f6bf9e6 100644 --- a/introspection/Makefile.in +++ b/introspection/Makefile.in @@ -330,6 +330,7 @@ NEWT_LIBS = @NEWT_LIBS@ NM = @NM@ NMEDIT = @NMEDIT@ NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT = @NM_CONFIG_DEFAULT_AUTH_POLKIT_TEXT@ +NM_CONFIG_DEFAULT_DNS_RC_MANAGER = @NM_CONFIG_DEFAULT_DNS_RC_MANAGER@ NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT = @NM_CONFIG_DEFAULT_LOGGING_AUDIT_TEXT@ NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT = @NM_CONFIG_LOGGING_BACKEND_DEFAULT_TEXT@ NM_MAJOR_VERSION = @NM_MAJOR_VERSION@ diff --git a/introspection/nm-ip4-config.xml b/introspection/nm-ip4-config.xml index c2a0f068..bbe7bebe 100644 --- a/introspection/nm-ip4-config.xml +++ b/introspection/nm-ip4-config.xml @@ -76,6 +76,13 @@ --> + + + + + + + + + +