- 15 Jan, 2020 2 commits
-
-
Beniamino Galvani authored
Allow changing the cloned MAC address for OVS bridges and interfaces. The MAC address set on the bridge is propagated by ovs to the local interface (the one with the same name as the bridge), while all other internal interfaces use the address defined in the interface connection. https://bugzilla.redhat.com/show_bug.cgi?id=1763734 https://bugzilla.redhat.com/show_bug.cgi?id=1740557 !321 (cherry picked from commit 101e65d2) (cherry picked from commit b366234a) (cherry picked from commit 5a4a5f63) (cherry picked from commit 46bb51d3)
-
Beniamino Galvani authored
(cherry picked from commit 508c7679) (cherry picked from commit ad17cfff) (cherry picked from commit 836b9e24) (cherry picked from commit adc76d28)
-
- 24 Dec, 2019 1 commit
-
-
Beniamino Galvani authored
The autoconnection for virtual devices currently works in two phases. First we detect that there is suitable profile that can autoconnect and we realize the device. Then, when the device becomes 'disconnected', autoconnect kicks in and starts the activation. However, if autoconnect is blocked for a device, currently we do step 1 without step 2, leaving a stale interface around. Fix this by also checking that autoconnect is not blocked during step 1. https://bugzilla.redhat.com/show_bug.cgi?id=1765047 !360 (cherry picked from commit 6c716912) (cherry picked from commit 944ff9f9) (cherry picked from commit cbb1ad1b) (cherry picked from commit dc03a264) (cherry picked from commit 1158d019)
-
- 20 Dec, 2019 1 commit
-
-
Thomas Haller authored
Otherwise, this function cannot really be used via generated bindings. Also, it's the only way to actually retrieve the set vlan-ids, without it, you wouldn't know which ones are set. Fixes: a9b4532f ('libnm-core: add SR-IOV setting') (cherry picked from commit c4a72821) (cherry picked from commit 49376697) (cherry picked from commit 2f62e30b) (cherry picked from commit a8746f48) (cherry picked from commit abd4cde1)
-
- 13 Sep, 2019 1 commit
-
-
Beniamino Galvani authored
wifi.seen-bssid is a synthetic read-only property that lists all the bssids seen for that connection; it should be ignored during a reapply. #243 (cherry picked from commit 8cd8a5fb) (cherry picked from commit 81cc4ddb) (cherry picked from commit ade98643) (cherry picked from commit ea30bffb)
-
- 05 Aug, 2019 1 commit
-
- 01 Aug, 2019 4 commits
-
-
Beniamino Galvani authored
!216 https://bugzilla.redhat.com/show_bug.cgi?id=1733709 (cherry picked from commit 5f668b81) (cherry picked from commit 0581a53a) (cherry picked from commit e066ac55) (cherry picked from commit ba484939)
-
Beniamino Galvani authored
Not all masters type have a platform link and so it's wrong to check for it to decide whether the slave should be really released. Move the check to master devices that need it (bond, bridge and team). OVS ports don't need the check because they don't call to platform to remove a slave. https://bugzilla.redhat.com/show_bug.cgi?id=1733709 (cherry picked from commit 57e3734b) (cherry picked from commit ec1b5fb0) (cherry picked from commit f6a90b89) (cherry picked from commit af2a126d)
-
Beniamino Galvani authored
We set nm-owned to indicate whether a software device was created by NM or it was pre-existing. When checking the existence, we must verify also whether the link type is compatible with the device, otherwise it is possible to match unrelated interfaces. For example, when checking for the existence of an ovs-bridge (which is not compatible with any platform link) we could match a unrelated platform link with the same name. https://bugzilla.redhat.com/show_bug.cgi?id=1733709 (cherry picked from commit 3cb4b362) (cherry picked from commit cb20d079) (cherry picked from commit 511ef27d) (cherry picked from commit 33309f7c)
-
Beniamino Galvani authored
An OVS bridge and its slaves can continue to work even after NM has quit. Keep the interface enslaved when the @configure argument of device->release_slave() is FALSE, which happens on quit and in other circumstances when we don't really want to release the slave from its master. https://bugzilla.redhat.com/show_bug.cgi?id=1733709 !215 (cherry picked from commit ccd4be40) (cherry picked from commit a1f39b69) (cherry picked from commit f93018a4)
-
- 23 Jul, 2019 1 commit
-
-
Thomas Haller authored
Kernel 5.2 is adding stricter checking for netlink messages. In particular, for certain API it checks now that NLA_F_NESTED flag is set for nested attributes ([1]). Note that libnl3 does not ever set this flag, and since our netlink implementation is copied from there, certain netlink messages are now rejected as invalid. On the other hand, libmnl always adds this flag ([2]). So we should do that as well. In particular, this affects the WireGuard netlink API causing request from NetworkManager to be rejected ([3]). [1] https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=b424e432e770d6dd572765459d5b6a96a19c5286 [2] https://git.netfilter.org/libmnl/tree/src/attr.c?id=5937dfcb0185f5cb9cf275992ea701ec4e619d9c#n535 [3] #212 !210 (cherry picked from commit 7811d1c1) (cherry picked from commit 57048338) (cherry picked from commit 52b52d2f)
-
- 22 Jul, 2019 1 commit
-
-
To create a disambiguated name for some Bluetooth devices we use its type name with iface, however this value is allocated but never free'd when passed to g_strdup_printf. So use instead a temporary variable and free it once done. !208 Fixes: 8bbda5cd (cherry picked from commit b621aba5) (cherry picked from commit 64ed96fb) (cherry picked from commit 6156720c)
-
- 18 Jul, 2019 1 commit
-
-
Thomas Haller authored
4 properties are not really relevant for an already activated connection or it makes not sense to change them. These are connection.id, connection.uuid, connection.autoconnect and connection.stable-id. For convenience, we allow to reapply these. This way, one can take a different setting (e.g. with a different connection.id or connection.uuid) and reapply them, but such changes are silently ignored. However this was done wrongly. Instead of reverting the change to the new applied connection, we would change the input connection. This is bad, for example with nmcli connection up uuid cb922f18-e99a-49c6-b200-1678b5070a82 nmcli connection modify cb922f18-e99a-49c6-b200-1678b5070a82 con-name "bogus" nmcli device reapply eth0 the last re-apply would reset the settings-connection's connection ID to what was before, while accepting the new name on the applied-connection (while it should have been rejected). Fixes: bf3b3d44 ('device: avoid changing immutable properties during reapply') (cherry picked from commit adb51c2a) (cherry picked from commit 09f37d5b) (cherry picked from commit 9c72ca5e)
-
- 09 Jul, 2019 1 commit
-
-
Thomas Haller authored
https://bugzilla.redhat.com/show_bug.cgi?id=1727193 Fixes: 433d2f86 ('core: merge IPv4 and IPv6 version of _nm_ip_config_merge_route_attributes()') (cherry picked from commit a8fa015a) (cherry picked from commit 44e4ed1e) (cherry picked from commit d3b7b0d2)
-
- 04 Jul, 2019 1 commit
-
-
Beniamino Galvani authored
(cherry picked from commit c0452678) (cherry picked from commit 4150dd8c) (cherry picked from commit 4aa2773f)
-
- 03 Jul, 2019 1 commit
-
-
Beniamino Galvani authored
NMDevicePPP only handles connections with the pppoe.parent property set. match_connection() already checks this when we creating a new device. We should also perform the same check in check_connection_compatible(). Fixes: 6c319593 ('core: implement activation of PPP devices') #203 (cherry picked from commit 17f4a1e7) (cherry picked from commit 5ca888d6) (cherry picked from commit ae4e82c3)
-
- 27 Jun, 2019 1 commit
-
-
Beniamino Galvani authored
Use the 'x' conversion specifier for hexadecimal numbers. Fixes: f53218ed ('cli: add property type for enum and showcase for ipv6.addr-gen-mode'): (cherry picked from commit 420554a7) (cherry picked from commit 9fe7ef6c) (cherry picked from commit d4141a18)
-
- 11 Jun, 2019 2 commits
-
-
Thomas Haller authored
Also, plan right away to backport this symbol all the way back to 1.14.8. As such, we only need to add it once, with the right linker version "libnm_1_14_8". But still, the symbols first appears on a major release 1.20.0. (cherry picked from commit a4c14895) (cherry picked from commit a7322eaa) (cherry picked from commit ad6eaa08)
-
Thomas Haller authored
-
- 20 May, 2019 1 commit
-
-
Beniamino Galvani authored
The teamd instance must not be killed if the device was externally activated. !158 https://bugzilla.redhat.com/show_bug.cgi?id=1693142 (cherry picked from commit 008a4b42) (cherry picked from commit bd113fe7) (cherry picked from commit c71b4726)
-
- 19 May, 2019 1 commit
-
-
This will be the default for Slackware 15.0 and on. This should be safe for both master and 1.12.x stable branch, as no existing Slackware releases are expected to run NM-1.12.x or later. Signed-off-by:
Robby Workman <rworkman@slackware.com> https://mail.gnome.org/archives/networkmanager-list/2019-May/msg00011.html (cherry picked from commit e1df17e0) (cherry picked from commit 065e8104) (cherry picked from commit 6160888e)
-
- 14 May, 2019 1 commit
-
-
Thomas Haller authored
Ooherwise, the file has wrong permissions: # ls -la /var/lib/NetworkManager/secret_key ----r-xr-x. 1 root root 50 May 14 13:52 /var/lib/NetworkManager/secret_key Luckily, /var/lib/NetworkManager should be already # ls -lad /var/lib/NetworkManager drwx------. 2 root root 8192 May 14 13:57 /var/lib/NetworkManager which mitigates this a bit. Fixes: dbcb1d6d ('core: let nm_utils_secret_key_read() handle failures internally') #175 (cherry picked from commit dc3a2f9b) (cherry picked from commit 2d46247c) (cherry picked from commit 7a0f8520)
-
- 10 May, 2019 2 commits
-
-
Thomas Haller authored
The boolean value is intended to indicate success. It would indicated failure due to a bug. Fixes: 297d4985 ('core/dbus: rework D-Bus implementation to use lower layer GDBusConnection API'): (cherry picked from commit 22e830f0) (cherry picked from commit e73a5058) (cherry picked from commit 1337ebd9)
-
Thomas Haller authored
$ busctl call org.freedesktop.NetworkManager /org/freedesktop/NetworkManager/Settings org.freedesktop.NetworkManager.Settings LoadConnections as 1 relative/filename triggers a g_critical() assertion in nm_utils_file_is_in_path(): ... #3 0x00007ffff7a19e7d in g_return_if_fail_warning (log_domain=log_domain@entry=0x55555586c333 "NetworkManager", pretty_function=pretty_function@entry=0x55555586c0a0 <__FUNCTION__.38585> "nm_utils_file_is_in_path", expression=expression@entry=0x55555586c010 "abs_filename && abs_filename[0] == '/'") at ../glib/gmessages.c:2767 #4 0x00005555555f1128 in nm_utils_file_is_in_path (abs_filename=abs_filename@entry=0x555555b56670 "dfd", abs_path=<optimized out>) at src/NetworkManagerUtils.c:1077 #5 0x00005555555a4779 in load_connection (config=<optimized out>, filename=0x555555b56670 "dfd") at src/settings/plugins/keyfile/nms-keyfile-plugin.c:522 #6 0x00005555557ce291 in nm_settings_plugin_load_connection (self=0x5555559fd400 [NMSKeyfilePlugin], filename=0x555555b56670 "dfd") at src/settings/nm-settings-plugin.c:70 #7 0x000055555559ccdf in impl_settings_load_connections (obj=<optimized out>, interface_info=<optimized out>, method_info=<optimized out>, connection=<optimized out>, sender=<optimized out>, invocation=0x7fffe0015ed0 [GDBusMethodInvocation], parameters=<optimized out>) at src/settings/nm-settings.c:1439 #8 0x00005555555a9bf9 in dbus_vtable_method_call (connection=0x5555559b91b0 [GDBusConnection], sender=sender@entry=0x555555b5c360 ":1.32283", object_path=object_path@entry=0x7fffe0019070 "/org/freedesktop/NetworkManager/Settings", interface_name=<optimized out>, interface_name@entry=0x7fffe002aa70 "org.freedesktop.NetworkManager.Settings", method_name=<optimized out>, method_name@entry=0x7fffe00276b0 "LoadConnections", parameters=parameters@entry=0x555555c4a690, invocation=0x7fffe0015ed0 [GDBusMethodInvocation], user_data=0x5555559a1a00) at src/nm-dbus-manager.c:947 #9 0x00007ffff7c506c4 in call_in_idle_cb (user_data=user_data@entry=0x7fffe0015ed0) at ../gio/gdbusconnection.c:4874 #10 0x00007ffff7a0e8eb in g_idle_dispatch (source=source@entry=0x7fffe00208a0, callback=0x7ffff7c50590 <call_in_idle_cb>, user_data=0x7fffe0015ed0) at ../glib/gmain.c:5627 #11 0x00007ffff7a11fd0 in g_main_dispatch (context=0x555555994d00) at ../glib/gmain.c:3189 #12 0x00007ffff7a11fd0 in g_main_context_dispatch (context=context@entry=0x555555994d00) at ../glib/gmain.c:3854 #13 0x00007ffff7a12368 in g_main_context_iterate (context=0x555555994d00, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at ../glib/gmain.c:3927 #14 0x00007ffff7a126b3 in g_main_loop_run (loop=0x555555995e60) at ../glib/gmain.c:4123 #15 0x000055555558a741 in main (argc=<optimized out>, argv=<optimized out>) at src/main.c:444 Filter out relative filenames early. (cherry picked from commit a1b102ea) (cherry picked from commit c21171e0) (cherry picked from commit 8fe900d3)
-
- 18 Apr, 2019 1 commit
-
-
Thomas Haller authored
Why didn't we get a compiler warning about this bug? At least clang (3.8.0-2ubuntu4, Ubuntu 16.04) warns: CC src/platform/src_libNetworkManagerBase_la-nm-platform.lo ../src/platform/nm-platform.c:5389:14: error: data argument not used by format string [-Werror,-Wformat-extra-args] lnk->remote ? nm_sprintf_buf (str_remote, " remote %s", nm_utils_inet4_ntop (lnk->remote, str_remote1)) : "", ^ Fixes: 4c2862b9 ('platform: add gretap tunnels support') (cherry picked from commit dfb899f4) (cherry picked from commit ed88c71f) (cherry picked from commit 400293d3)
-
- 10 Apr, 2019 1 commit
-
-
Beniamino Galvani authored
If NM fails to connect to teamd, it currently just sets the device state to FAILED and waits that deactivate() is called later. However, the 5 seconds timeout on teamd process start can hit in the meantime, which fails with an assertion "nm_device_is_activating (device)". Clean up the device state when the connection to teamd fails. https://bugzilla.redhat.com/show_bug.cgi?id=1697900 (cherry picked from commit c48698d7) (cherry picked from commit 43571d10)
-
- 09 Apr, 2019 1 commit
-
-
Beniamino Galvani authored
When we delete the runner.name property, the runner object itself gets deleted if that was the only property, and @runner becomes invalid. ==13818== Invalid read of size 1 ==13818== at 0x55EAF4: nm_streq (nm-macros-internal.h:869) ==13818== by 0x55EAF4: _json_team_normalize_defaults (nm-utils.c:5573) ==13818== by 0x566C89: _nm_utils_team_config_set (nm-utils.c:6057) ==13818== by 0x5498A6: _nm_utils_json_append_gvalue (nm-utils-private.h:228) ==13818== by 0x5498A6: set_property (nm-setting-team.c:1622) ==13818== Address 0x182a9330 is 0 bytes inside a block of size 13 free'd ==13818== at 0x4839A0C: free (vg_replace_malloc.c:530) ==13818== by 0x4857868: json_delete_string (value.c:763) ==13818== by 0x4857868: json_delete (value.c:975) ==13818== by 0x4851FA1: UnknownInlinedFun (jansson.h:129) ==13818== by 0x4851FA1: hashtable_do_del (hashtable.c:131) ==13818== by 0x4851FA1: hashtable_del (hashtable.c:289) ==13818== by 0x55DFDD: _json_del_object (nm-utils.c:5384) ==13818== by 0x55EA70: _json_delete_object_on_string_match (nm-utils.c:5532) ==13818== by 0x55EADB: _json_team_normalize_defaults (nm-utils.c:5549) ==13818== by 0x566C89: _nm_utils_team_config_set (nm-utils.c:6057) ==13818== by 0x5498A6: _nm_utils_json_append_gvalue (nm-utils-private.h:228) ==13818== by 0x5498A6: set_property (nm-setting-team.c:1622) ==13818== Block was alloc'd at ==13818== at 0x483880B: malloc (vg_replace_malloc.c:299) ==13818== by 0x4852E8C: lex_scan_string (load.c:389) ==13818== by 0x4852E8C: lex_scan (load.c:620) ==13818== by 0x4853458: parse_object (load.c:738) ==13818== by 0x4853458: parse_value (load.c:862) ==13818== by 0x4853466: parse_object (load.c:739) ==13818== by 0x4853466: parse_value (load.c:862) ==13818== by 0x4853655: parse_json.constprop.7 (load.c:899) ==13818== by 0x48537CF: json_loads (load.c:959) ==13818== by 0x566780: _nm_utils_team_config_set (nm-utils.c:5961) ==13818== by 0x5498A6: _nm_utils_json_append_gvalue (nm-utils-private.h:228) ==13818== by 0x5498A6: set_property (nm-setting-team.c:1622) Fixes: a5642fd9 ('libnm-core: team: rework defaults management on runner properties') (cherry picked from commit 80a3031a) (cherry picked from commit 3fa39f61)
-
- 02 Apr, 2019 1 commit
-
-
Fixes: 6aa66426 ('settings/ifupdown: merge eni_ifaces and connections hashes in plugin') #145 https://bugzilla.redhat.com/show_bug.cgi?id=1694912 (cherry picked from commit 1dd67583) (cherry picked from commit 00858afc)
-
- 31 Mar, 2019 1 commit
-
-
Beniamino Galvani authored
The 4th argument of AC_SEARCH_LIBS is a list of additional libraries, not the name of the variable to hold the result which is always ac_cv_search_$function. Also, we should ignore the result when it is "none required". Fixes: 1f2eeb85 ('build: rename $(LIBDL) to $(DL_LIBS) and modify detection') (cherry picked from commit bd4957fc) (cherry picked from commit 1fa0914b)
-
- 26 Mar, 2019 1 commit
-
-
Beniamino Galvani authored
The error was leaked when cancelled. Fixes: 818023c2 ('dns/resolved: add systemd-resolved backend') (cherry picked from commit 579373a5) (cherry picked from commit 065fa283)
-
- 15 Mar, 2019 1 commit
-
-
Beniamino Galvani authored
Fixes: a8d60052 ('libnm: implement support for DNS manager properties') https://bugzilla.redhat.com/show_bug.cgi?id=1689055 (cherry picked from commit d867837d) (cherry picked from commit 47f1c931)
-
- 11 Mar, 2019 1 commit
-
-
Thomas Haller authored
On Fedora rawhide we get the following build failure: In file included from shared/systemd/src/basic/alloc-util.c:3: ./shared/systemd/sd-adapt-shared/nm-sd-adapt-shared.h:114:21: error: static declaration of 'gettid' follows non-static declaration 114 | static inline pid_t gettid(void) { | ^~~~~~ In file included from /usr/include/unistd.h:1170, from /usr/include/glib-2.0/gio/gcredentials.h:32, from /usr/include/glib-2.0/gio/gio.h:46, from ./shared/nm-utils/nm-macros-internal.h:31, from ./shared/nm-default.h:293, from ./shared/systemd/sd-adapt-shared/nm-sd-adapt-shared.h:22, from shared/systemd/src/basic/alloc-util.c:3: /usr/include/bits/unistd_ext.h:34:16: note: previous declaration of 'gettid' was here 34 | extern __pid_t gettid (void) __THROW; | ^~~~~~ glibc supports now gettid() call ([1]) which conflicts with our compat implementation. Rename it. [1] https://sourceware.org/git/?p=glibc.git;a=commit;h=1d0fc213824eaa2a8f8c4385daaa698ee8fb7c92 (cherry picked from commit 10276322) (cherry picked from commit cfb970b2)
-
- 08 Mar, 2019 1 commit
-
-
Lubomir Rintel authored
Otherwise it will be dereferencing NULL when invoked. Fixes: 58712c95 ('ofono: take D-Bus proxy for ConnectionManager asynchronously') https://github.com/NetworkManager/NetworkManager/pull/313 (cherry picked from commit 90fe78eb) (cherry picked from commit 4d4b3fc8)
-
- 07 Mar, 2019 2 commits
-
-
Lubomir Rintel authored
The condition got accidentally reversed, which means we're always undecided and thus wrongly assuming support and never being able to set any addresses. This would bother the few that are struck with 3.4 android kernels. Very few indeed, given this got unnoticed since 1.10. Fixes: 8670aacc ('platform: cleanup detecting kernel support for IFA_FLAGS and IPv6LL') (cherry picked from commit d551a089) (cherry picked from commit c411b890)
-
- 05 Mar, 2019 2 commits
-
-
Beniamino Galvani authored
Delay ARP announcements for masters until the first interfaces gets enslaved. There is no point in doing it before as the ARP packets would be dropped in most cases; also, if the first slave is added when we already started announcing, the MAC of the master is going to change and so the remaining ARPs will have a wrong "sender mac address" field. https://bugzilla.redhat.com/show_bug.cgi?id=1678796 https://github.com/NetworkManager/NetworkManager/pull/301
-
Thomas Haller authored
CC clients/nm_online-nm-online.o In file included from ./shared/nm-default.h:311:0, from clients/nm-online.c:34: ./libnm/NetworkManager.h:60:10: fatal error: nm-enum-types.h: No such file or directory #include "nm-enum-types.h" ^~~~~~~~~~~~~~~~~ (cherry picked from commit d8070c7a) (cherry picked from commit a79d9dac)
-
- 04 Mar, 2019 1 commit
-
-
Beniamino Galvani authored
This change allows NM to assume after a restart a device that has been enslaved externally to an ovs bridge. https://bugzilla.redhat.com/show_bug.cgi?id=1676551 (cherry picked from commit 93bbe436) (cherry picked from commit 526f1476)
-
- 27 Feb, 2019 1 commit
-
-
Thomas Haller authored
The tests run nmcli with Polish locale and compare the output. After modifying Polish translation we must regenerate the expected output. Fixes: 25d91e3b
-
- 26 Feb, 2019 1 commit
-
-
Beniamino Galvani authored
wpa_supplicant only advertises pmf support since commit [1], which is after 2.6. When using a version without that commit (for example, plain 2.6), we would unconditionally set the global Pmf property to 1 (optional) and then skip setting the per-network property. The result was that pmf was enabled without the possibility to disable it by user. The correct behavior is instead to disable pmf on such versions. [1] https://w1.fi/cgit/hostap/commit/?id=3cdb4ac074f76accf24a51d143db545afad2c90b #129 (cherry picked from commit 560a35dd) (cherry picked from commit b837561b)
-