summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* libnm: add LLDP supportbg/lldp-rh1142898-v4Beniamino Galvani2015-10-073-0/+289
| | | | | Add functions to libnm for retrieving a list of LLDP neighbors and accessor functions to get their attributes.
* device: export list of LLDP neighbors through D-BusBeniamino Galvani2015-10-078-0/+817
| | | | | | | This adds a LldpNeighbors property to the Device D-Bus interface carrying information about devices discovered through LLDP. The property is an array of hashes and each hash describes the values of LLDP TLVs for a specific neighbor.
* libnm,cli: add 'lldp' property to NMSettingConnectionBeniamino Galvani2015-10-077-2/+125
| | | | | | Add the 'lldp' property to NMSettingConnection, which specifies whether the reception and parsing of LLDP frames to discover neighbor devices should be enabled.
* Merge branch 'systemd' into bg/lldp-rh1142898-v4Beniamino Galvani2015-10-0754-1046/+7065
|\
| * systemd: update code from upstreamBeniamino Galvani2015-10-0749-1020/+6966
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a direct dump from systemd git on 2015-10-07, git commit 69b8a8ebaeaae13e82d44b386555921877bc0309. ====== SYSTEMD_DIR=../systemd COMMIT=69b8a8ebaeaae13e82d44b386555921877bc0309 ( cd "$SYSTEMD_DIR" git checkout "$COMMIT" git reset --hard git clean -fdx ) git ls-files :/src/systemd/src/ | xargs -d '\n' rm -f nm_copy_sd() { mkdir -p "./src/systemd/$(dirname "$1")" cp "$SYSTEMD_DIR/$1" "./src/systemd/$1" } nm_copy_sd "src/basic/async.h" nm_copy_sd "src/basic/fileio.c" nm_copy_sd "src/basic/fileio.h" nm_copy_sd "src/basic/hashmap.h" nm_copy_sd "src/basic/hashmap.c" nm_copy_sd "src/basic/hostname-util.c" nm_copy_sd "src/basic/hostname-util.h" nm_copy_sd "src/basic/in-addr-util.c" nm_copy_sd "src/basic/in-addr-util.h" nm_copy_sd "src/basic/list.h" nm_copy_sd "src/basic/log.h" nm_copy_sd "src/basic/macro.h" nm_copy_sd "src/basic/mempool.h" nm_copy_sd "src/basic/mempool.c" nm_copy_sd "src/basic/path-util.c" nm_copy_sd "src/basic/path-util.h" nm_copy_sd "src/basic/prioq.h" nm_copy_sd "src/basic/prioq.c" nm_copy_sd "src/basic/random-util.c" nm_copy_sd "src/basic/random-util.h" nm_copy_sd "src/basic/refcnt.h" nm_copy_sd "src/basic/set.h" nm_copy_sd "src/basic/siphash24.c" nm_copy_sd "src/basic/siphash24.h" nm_copy_sd "src/basic/socket-util.h" nm_copy_sd "src/basic/sparse-endian.h" nm_copy_sd "src/basic/strv.c" nm_copy_sd "src/basic/strv.h" nm_copy_sd "src/basic/time-util.c" nm_copy_sd "src/basic/time-util.h" nm_copy_sd "src/basic/unaligned.h" nm_copy_sd "src/basic/utf8.c" nm_copy_sd "src/basic/utf8.h" nm_copy_sd "src/basic/util.c" nm_copy_sd "src/basic/util.h" nm_copy_sd "src/libsystemd-network/arp-util.c" nm_copy_sd "src/libsystemd-network/arp-util.h" nm_copy_sd "src/libsystemd-network/dhcp6-internal.h" nm_copy_sd "src/libsystemd-network/dhcp6-lease-internal.h" nm_copy_sd "src/libsystemd-network/dhcp6-network.c" nm_copy_sd "src/libsystemd-network/dhcp6-option.c" nm_copy_sd "src/libsystemd-network/dhcp6-protocol.h" nm_copy_sd "src/libsystemd-network/dhcp-identifier.c" nm_copy_sd "src/libsystemd-network/dhcp-identifier.h" nm_copy_sd "src/libsystemd-network/dhcp-internal.h" nm_copy_sd "src/libsystemd-network/dhcp-lease-internal.h" nm_copy_sd "src/libsystemd-network/dhcp-network.c" nm_copy_sd "src/libsystemd-network/dhcp-option.c" nm_copy_sd "src/libsystemd-network/dhcp-packet.c" nm_copy_sd "src/libsystemd-network/dhcp-protocol.h" nm_copy_sd "src/libsystemd-network/lldp.h" nm_copy_sd "src/libsystemd-network/lldp-internal.h" nm_copy_sd "src/libsystemd-network/lldp-internal.c" nm_copy_sd "src/libsystemd-network/lldp-network.h" nm_copy_sd "src/libsystemd-network/lldp-network.c" nm_copy_sd "src/libsystemd-network/lldp-port.c" nm_copy_sd "src/libsystemd-network/lldp-port.h" nm_copy_sd "src/libsystemd-network/lldp-tlv.c" nm_copy_sd "src/libsystemd-network/lldp-tlv.h" nm_copy_sd "src/libsystemd-network/lldp-util.h" nm_copy_sd "src/libsystemd-network/network-internal.c" nm_copy_sd "src/libsystemd-network/network-internal.h" nm_copy_sd "src/libsystemd-network/sd-dhcp6-client.c" nm_copy_sd "src/libsystemd-network/sd-dhcp6-lease.c" nm_copy_sd "src/libsystemd-network/sd-dhcp-client.c" nm_copy_sd "src/libsystemd-network/sd-dhcp-lease.c" nm_copy_sd "src/libsystemd-network/sd-ipv4ll.c" nm_copy_sd "src/libsystemd-network/sd-ipv4acd.c" nm_copy_sd "src/libsystemd-network/sd-lldp.c" nm_copy_sd "src/libsystemd/sd-id128/sd-id128.c" nm_copy_sd "src/libsystemd/sd-event/event-util.h" nm_copy_sd "src/shared/dns-domain.c" nm_copy_sd "src/shared/dns-domain.h" nm_copy_sd "src/systemd/_sd-common.h" nm_copy_sd "src/systemd/sd-dhcp6-client.h" nm_copy_sd "src/systemd/sd-dhcp6-lease.h" nm_copy_sd "src/systemd/sd-dhcp-client.h" nm_copy_sd "src/systemd/sd-dhcp-lease.h" nm_copy_sd "src/systemd/sd-event.h" nm_copy_sd "src/systemd/sd-icmp6-nd.h" nm_copy_sd "src/systemd/sd-id128.h" nm_copy_sd "src/systemd/sd-ipv4acd.h" nm_copy_sd "src/systemd/sd-ipv4ll.h" nm_copy_sd "src/systemd/sd-lldp.h"
* | device: assert that master-ready handler is not scheduled in ↵baserock/1.1.0-dev-1952-gc41be46Thomas Haller2015-10-061-2/+3
| | | | | | | | schedule_stage2_device_config()
* | device: handle master-ready before scheduling stage2Thomas Haller2015-10-061-22/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Don't handle master-ready at the beginning of stage2, but instead while scheduling (and then possibly delaying the scheduling of stage2). This seems more idiomatic: When inside a stage and your part is done: call schedule-next-stage. That is, always schedule the next stage, not the current one. schedule-next-stage then might delay to really scheduling until the device is ready for the next state. Fixes: 85ac903bb8010409c4010ba09c621780b385b9b5
* | device: fix activating master/slave devices during stage2Thomas Haller2015-10-061-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | During stage2, if the slave detected that it would need to wait for the master, it would return FALSE (which removes the g-idle-handler). However, it would not clear the activation-source, so later, when the master becomes ready, its attempt to schedule stage2 again would result in an error-log and the idle-handler would not be scheduled again. Fixes: 85ac903bb8010409c4010ba09c621780b385b9b5 https://bugzilla.redhat.com/show_bug.cgi?id=1268797 https://bugzilla.redhat.com/show_bug.cgi?id=1183444
* | dbus: allow talking to fortisslvpn pluginLubomir Rintel2015-10-061-0/+1
| |
* | ifcfg-rh: don't disallow console users from owning the bus nameLubomir Rintel2015-10-061-1/+0
| | | | | | | | | | Root can be logged on console and this would prevent NM from acquiring the bus name. Non-privileged users are covered by the default policy anyway.
* | merge: branch 'lr/ipv4-dhcp-timeout-rh1262922'Lubomir Rintel2015-10-0612-11/+126
|\ \ | | | | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1262922
| * | cli: add support for ipv4.dhcp-timeout propertylr/ipv4-dhcp-timeout-rh1262922Lubomir Rintel2015-10-061-8/+19
| | | | | | | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1262922
| * | device: allow overriding the DHCPv4 timeoutLubomir Rintel2015-10-061-1/+1
| | | | | | | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1262922
| * | ifcfg-rh: add IPV4_DHCP_TIMEOUT key for ipv4.dhcp-timeout propertyLubomir Rintel2015-10-062-2/+8
| | | | | | | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1262922
| * | libnm-util: add ipv4.dhcp-timeout propertyLubomir Rintel2015-10-064-0/+44
| | | | | | | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1262922
| * | libnm,ip4-config: add ipv4.dhcp-timeout propertyLubomir Rintel2015-10-064-0/+54
|/ / | | | | | | | | | | | | | | This is intentionally IPv4 specific since this is used for a quick fallback to method=link-local -- something that's not needed for IPv6 since the link local address is always there. https://bugzilla.redhat.com/show_bug.cgi?id=1262922
* | libnm: avoid notifying for objects until they're async-initedLubomir Rintel2015-10-061-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise the uninitializeded objects could be prematurely signalled if their paths are seen twice in quick succession. This happens when you have ethernet hardware and add an ethernet connection -- it's immediatelly added to AvialableConnections and the property reload signals the object addition before the NMRemoteSettings's GetSettings() finishes: # nmcli c add type ethernet autoconnect no ifname '*' (process:4610): libnm-CRITICAL **: nm_connection_get_id: assertion 's_con != NULL' failed Connection '(null)' ((null)) successfully added. # https://bugzilla.gnome.org/show_bug.cgi?id=754794
* | Revert "libnm: fix initializing of new connections"Lubomir Rintel2015-10-062-4/+1
| | | | | | | | This reverts commit d20bed069c718e161f0a2457c9fb8204fc5c9fac.
* | config: merge branch 'th/config-enable-bgo755935'Thomas Haller2015-10-0513-71/+555
|\ \ | | | | | | | | | https://bugzilla.gnome.org/show_bug.cgi?id=755935
| * | config: drop global-dns.enable option in favor of .config.enableThomas Haller2015-10-058-30/+32
| | | | | | | | | | | | | | | | | | | | | | | | No longer support disabling the global-dns configuration via the "enable" option. Instead, the user can put the entire dns-configuration in one separate snippet, and disable it altogether with ".config.enable".
| * | config: allow to enable/disable configuration snippetsThomas Haller2015-10-0510-6/+474
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Support a new configuration option [.config] enable=<ENABLED> for configuration snippets. This new [.config] section is only relevant within the snippet itself and it is not merged into the combined configuration. Currently only the "enable" key is supported. If the "enable" key is missing, it obviously defaults to being enabled. It allows snippets to be skipped from loading. The main configuration "NetworkManager.conf" cannot be skipped. <ENABLED> can be a boolean value (false), to skip a configuration snippet from loading. It can also be a string to match against the NetworkManager version, like "enable=nm-version-min:1.1,nm-version-min:1.0.6" There are several motivations for this: - the user can disable an entire configuration snippet by toggeling one entry. This generalizes the functionality of the global-dns.enable setting, but in a way that applies to configuration on a per-file basis. - for developing, we often switch between different versions of NetworkManager. Thus, we might want to use different configuration. E.g. before global-dns options, I want to use "dns=none" and manage resolv.conf myself. Now, I can use global-dns setting to do that. That can be achieved with something like the following (not exactly, it's an example only): [.config] enable=nm-version-min:1.1 [main] dns=default [global-dns-domain-*] nameserver=127.0.0.1 Arguably, this would be more awesome, if we would bump our micro devel version (1.1.0) more often while developing 1.2.0 (*hint*). - in principle, packages could drop configuration snippets and enable them based on the NetworkManager version. - with the "env:" spec, you can enable/disable snippets by configuring an environment variable. Again, useful for testing and developing.
| * | core: add nm_utils_ascii_str_to_bool()Thomas Haller2015-10-053-26/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is effectively the same as nm_config_parse_boolean(). The difference is, that "nm-config.c" is not available to the interface-helper, thus any code used by interface-helper (like "NetworkManager.c") cannot use this function. Still don't drop nm_config_parse_boolean() entirely, because it's better to have the explicit notion of parsing a string in the config-context. I ended up not using the function. But I'd still keep this patch.
| * | config/trivial: rename nm_config_get_device_match_spec() to ↵Thomas Haller2015-10-053-9/+9
|/ / | | | | | | | | | | | | nm_config_get_match_spec() We want to use the term match-spec more generally and not only for "device-specs".
* | core: merge branch 'th/more-asserts'Thomas Haller2015-10-0514-63/+77
|\ \ | | | | | | | | | | | | Change NM_MORE_ASSERTS to allow for different levels for which asserts are enabled.
| * | device: add assertion to consistency of nm_device_check_connection_available()Thomas Haller2015-10-051-16/+51
| | |
| * | build: make NM_MORE_ASSERTS define numeric for different levels of more-assertsThomas Haller2015-10-055-6/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Allows to enable more-asserts more granularly. Unfortunately, the old check was "${enable_more_asserts} == "yes", thus we cannot extend "--enable-more-assert=level" because that would mean that the same build script cannot set the option on both old and new NetworkManager. Thus, add a new option --with-more-asserts=level. If you put the following in your build script, it will work as expected whether you build a new or an old version of NetworkManager. ./configure --enable-more-asserts --with-more-asserts=5
| * | build: include "config.h" in nm*enum-types.c sourcesThomas Haller2015-10-051-1/+1
| | | | | | | | | | | | | | | Also include the "config.h" file in the generated sources like "nm-enum-types.c".
| * | config: add missing include to "config.h" headerThomas Haller2015-10-051-0/+2
| | |
| * | build: drop generating empty nm-*-enum-types for device pluginsThomas Haller2015-10-056-40/+3
|/ / | | | | | | | | The device plugins adsl, team and wifi were generating empty "nm-*-enum-types" header and source files.
* | device: use _LOG() logging macros for per-device loggingThomas Haller2015-10-051-6/+5
| |
* | libnm: use nm_clear_g_source() in nm-object.cThomas Haller2015-10-031-4/+2
| |
* | wifi: align logging AP dumpsThomas Haller2015-10-031-1/+1
| | | | | | | | | | There are several places where we log the APs. It looks nicer in the log, if all use the same length prefix.
* | wifi: fix alignment of logging strength in nm_ap_dump()Thomas Haller2015-10-031-2/+1
| |
* | bus-manager: fix handling of incoming signalsBeniamino Galvani2015-10-031-12/+41
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The 'new-connection' signal of a GDBusServer is emitted by default through an idle source and the actual message processing starts only after a signal handler returns TRUE. Thus, before the signal handler has the chance to run, the GDBus worker thread may detect that the connection is closed and schedule the delivery of the 'closed' signal through another idle source. After the termination of the 'new-connection' handler, the 'closed' handler is executed, which cancels the subscription to GDBus signals before any message has been processed. This looks like a bug in GDBusServer; to work around it, just delay the close of connection to let the signal dispatch run first. https://bugzilla.gnome.org/show_bug.cgi?id=755170
* | code: merge branch 'th/enslave-team-rh1183444'Thomas Haller2015-10-022-30/+54
|\ \ | | | | | | | | | https://bugzilla.redhat.com/show_bug.cgi?id=1183444
| * | device: fix activating slave device when stage1 delays actionThomas Haller2015-10-021-23/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When activating for example a team device which is to be enslaved to a bridge, nm_device_activate_stage1_device_prepare() will postpone stage 2. In that case, we didn't register the "master-ready" of the team device and thus never progressed the slave from stage2. Reproduce: # nmcli connection delete t-br0 # nmcli connection delete t-team0 nmcli connection add type bridge con-name t-br0 autoconnect no ifname i-br0 ip4 192.168.177.100/24 gw4 192.168.177.1 nmcli connection add type team con-name t-team0 autoconnect no ifname i-team0 nmcli connection modify id t-team0 connection.master i-br0 connection.slave-type bridge nmcli connection up t-team0
| * | device: use nm_clear_g_signal_handler() to clear master-ready signal handlerThomas Haller2015-10-021-8/+2
| | |
| * | macros: add nm_clear_g_signal_handler() helperThomas Haller2015-10-021-0/+13
|/ /
* | config: initialize gs_free marked variableJiří Klimeš2015-10-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise I get the following error (iwhile building in Jenkins): In file included from ../include/nm-default.h:45:0, from nm-config.c:27: nm-config.c: In function 'nm_config_set_global_dns': ../include/gsystem-local-alloc.h:31:10: error: 'group_name' may be used uninitialized in this function [-Werror=maybe-uninitialized] func (*(Type*)v); \ ^ nm-config.c:1483:17: note: 'group_name' was declared here gs_free char *group_name; ^
* | wifi: emit NEW_BSS on ScanDone to update APs in Wi-Fi device (rh #1267327)Jiří Klimeš2015-10-021-15/+46
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When a Wi-Fi is switched to AP mode, NMDeviceWifi forgets the AP scan list. Later, when the device goes back to normal managed mode, the device was not able to acquire the AP list again (for a long time), because the list is only populated when a new BSS is signalled. And that could take very long or never happen as the supplicant would have to lost the BSS and announce it later. Fix the problem by announcing known BSSs as a response to ScanDone signal. Testcase: $ nmcli con add type wifi ifname wlan0 con-name my-wifi-ap autoconnect off ssid MYSSID $ nmcli con modify my-wifi-ap wifi.mode ap ipv4.method shared $ nmcli con up my-wifi-ap $ nmcli con down my-wifi-ap $ nmcli device wifi list https://bugzilla.redhat.com/show_bug.cgi?id=1267327
* | supplicant: fix BSSs property typeJiří Klimeš2015-10-021-1/+1
| | | | | | | | BSSs property is an array of object paths, not strings.
* | nm-vpn-service-plugin: increase the quit timerLubomir Rintel2015-10-013-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | We now (since 3272ff6 libnm/libnm-glib: don't quit in the middle of asking for secrets) always hook on the quit timer when NM asks the plugin if it needs secrets. The timer is 20 seconds, which seems too short. Let's make it three minutes. Don't bother adding another timer or using a distinct timeout: it does no harm for the plugin to remain unused for three minutes on a bus. Another option would be to completely unhook it; however the plugin wouldn't learn if the user cancelled the NM's secrets request and would remain unused on the bus forever.
* | nm-config: drop a glib 2.40-ismLubomir Rintel2015-10-011-1/+1
| | | | | | | | Fixes: ae9e82354a9c1b2247b7d071ed62acd9e83ae27b
* | core: merge branch 'bg/global-dns-conf-bgo750458'Beniamino Galvani2015-10-0122-68/+1131
|\ \ | | | | | | | | | | | | | | | | | | Add support for a global DNS configuration read from user configuration file or set through D-Bus. https://bugzilla.gnome.org/show_bug.cgi?id=750458
| * | manager: export DNS global configuration D-Bus propertyBeniamino Galvani2015-10-019-16/+364
| | |
| * | man: document global DNS configuration sectionsBeniamino Galvani2015-10-011-0/+66
| | |
| * | dns: add support for global configuration in DNS managerBeniamino Galvani2015-10-017-52/+169
| | | | | | | | | | | | | | | | | | | | | Modify the DNS manager to use the static global DNS configuration when available. In addition, change DNS plugins interface to accept a new argument for global configuration and add support for this new parameter to the dnsmasq plugin.
| * | core: add support for reading global DNS configuration from keyfileBeniamino Galvani2015-10-019-0/+457
| | | | | | | | | | | | | | | | | | Add to the NMConfigData object information about global DNS configuration, which is loaded from user or internal keyfile upon object construction.
| * | glib-compat: add g_hash_table_get_keys_as_array() compat functionBeniamino Galvani2015-10-012-0/+75
|/ /
* | contrib/rpm: remove dbus-glib dependancyThomas Haller2015-09-301-1/+0
| | | | | | | | Only libnm-glib still requires dbus-glib.