<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/NetworkManager.git/libnm-core/nm-utils.c, branch th/fix-python-test</title>
<subtitle>gitlab.freedesktop.org: NetworkManager/NetworkManager.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/'/>
<entry>
<title>bluetooth: refactor BlueZ handling and let NMBluezManager cache ObjectManager data</title>
<updated>2019-09-23T10:47:37+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2019-08-11T08:43:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=4154d9618c904c2286b332b56f3515806cb1bb3b'/>
<id>4154d9618c904c2286b332b56f3515806cb1bb3b</id>
<content type='text'>
This is a complete refactoring of the bluetooth code.

Now that BlueZ 4 support was dropped, the separation of NMBluezManager
and NMBluez5Manager makes no sense. They should be merged.

At that point, notice that BlueZ 5's D-Bus API is fully centered around
D-Bus's ObjectManager interface. Using that interface, we basically only
call GetManagedObjects() once and register to InterfacesAdded,
InterfacesRemoved and PropertiesChanged signals. There is no need to
fetch individual properties ever.

Note how NMBluezDevice used to query the D-Bus properties itself by
creating a GDBusProxy. This is redundant, because when using the ObjectManager
interfaces, we have all information already.

Instead, let NMBluezManager basically become the client-side cache of
all of BlueZ's ObjectManager interface. NMBluezDevice was mostly concerned
about caching the D-Bus interface's state, tracking suitable profiles
(pan_connection), and moderate between bluez and NMDeviceBt.
These tasks don't get simpler by moving them to a seprate file. Let them
also be handled by NMBluezManager.

I mean, just look how it was previously: NMBluez5Manager registers to
ObjectManager interface and sees a device appearing. It creates a
NMBluezDevice object and registers to its "initialized" and
"notify:usable" signal. In the meantime, NMBluezDevice fetches the
relevant information from D-Bus (although it was already present in the
data provided by the ObjectManager) and eventually emits these usable
and initialized signals.
Then, NMBlue5Manager emits a "bdaddr-added" signal, for which NMBluezManager
creates the NMDeviceBt instance. NMBluezManager, NMBluez5Manager and
NMBluezDevice are strongly cooperating to the point that it is simpler
to merge them.

This is not mere refactoring. This patch aims to make everything
asynchronously and always cancellable. Also, it aims to fix races
and inconsistencies of the state.

- Registering to a NAP server now waits for the response and delays
  activation of the NMDeviceBridge accordingly.

- For NAP connections we now watch the bnep0 interface in platform, and tear
  down the device when it goes away. Bluez doesn't send us a notification
  on D-Bus in that case.

- Rework establishing a DUN connection. It no longer uses blocking
  connect() and does not block until rfcomm device appears. It's
  all async now. It also watches the rfcomm file descriptor for
  POLLERR/POLLHUP to notice disconnect.

- drop nm_device_factory_emit_component_added() and instead let
  NMDeviceBt directly register to the WWan factory's "added" signal.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This is a complete refactoring of the bluetooth code.

Now that BlueZ 4 support was dropped, the separation of NMBluezManager
and NMBluez5Manager makes no sense. They should be merged.

At that point, notice that BlueZ 5's D-Bus API is fully centered around
D-Bus's ObjectManager interface. Using that interface, we basically only
call GetManagedObjects() once and register to InterfacesAdded,
InterfacesRemoved and PropertiesChanged signals. There is no need to
fetch individual properties ever.

Note how NMBluezDevice used to query the D-Bus properties itself by
creating a GDBusProxy. This is redundant, because when using the ObjectManager
interfaces, we have all information already.

Instead, let NMBluezManager basically become the client-side cache of
all of BlueZ's ObjectManager interface. NMBluezDevice was mostly concerned
about caching the D-Bus interface's state, tracking suitable profiles
(pan_connection), and moderate between bluez and NMDeviceBt.
These tasks don't get simpler by moving them to a seprate file. Let them
also be handled by NMBluezManager.

I mean, just look how it was previously: NMBluez5Manager registers to
ObjectManager interface and sees a device appearing. It creates a
NMBluezDevice object and registers to its "initialized" and
"notify:usable" signal. In the meantime, NMBluezDevice fetches the
relevant information from D-Bus (although it was already present in the
data provided by the ObjectManager) and eventually emits these usable
and initialized signals.
Then, NMBlue5Manager emits a "bdaddr-added" signal, for which NMBluezManager
creates the NMDeviceBt instance. NMBluezManager, NMBluez5Manager and
NMBluezDevice are strongly cooperating to the point that it is simpler
to merge them.

This is not mere refactoring. This patch aims to make everything
asynchronously and always cancellable. Also, it aims to fix races
and inconsistencies of the state.

- Registering to a NAP server now waits for the response and delays
  activation of the NMDeviceBridge accordingly.

- For NAP connections we now watch the bnep0 interface in platform, and tear
  down the device when it goes away. Bluez doesn't send us a notification
  on D-Bus in that case.

- Rework establishing a DUN connection. It no longer uses blocking
  connect() and does not block until rfcomm device appears. It's
  all async now. It also watches the rfcomm file descriptor for
  POLLERR/POLLHUP to notice disconnect.

- drop nm_device_factory_emit_component_added() and instead let
  NMDeviceBt directly register to the WWan factory's "added" signal.
</pre>
</div>
</content>
</entry>
<entry>
<title>all: SPDX header conversion</title>
<updated>2019-09-10T09:19:56+00:00</updated>
<author>
<name>Lubomir Rintel</name>
<email>lkundrak@v3.sk</email>
</author>
<published>2019-09-10T09:19:01+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=24028a22467275671df71cc6a8054036b37d8f03'/>
<id>24028a22467275671df71cc6a8054036b37d8f03</id>
<content type='text'>
  $ find * -type f |xargs perl contrib/scripts/spdx.pl
  $ git rm contrib/scripts/spdx.pl
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
  $ find * -type f |xargs perl contrib/scripts/spdx.pl
  $ git rm contrib/scripts/spdx.pl
</pre>
</div>
</content>
</entry>
<entry>
<title>wifi: support WPA2 ad-hoc (ibss-rsn)</title>
<updated>2019-08-26T08:38:02+00:00</updated>
<author>
<name>Beniamino Galvani</name>
<email>bgalvani@redhat.com</email>
</author>
<published>2019-08-19T16:04:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=a205eb4aa41c5e35fb4171f7b7922da488a829dc'/>
<id>a205eb4aa41c5e35fb4171f7b7922da488a829dc</id>
<content type='text'>
If the device supports it, allow usage of WPA2 in ad-hoc networks.

Based-on-patch-by: Nicolas Cavallari &lt;cavallar@lri.fr&gt;

https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/184
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If the device supports it, allow usage of WPA2 in ad-hoc networks.

Based-on-patch-by: Nicolas Cavallari &lt;cavallar@lri.fr&gt;

https://gitlab.freedesktop.org/NetworkManager/NetworkManager/issues/184
</pre>
</div>
</content>
</entry>
<entry>
<title>wifi: drop support for wpa-none key-mgmt</title>
<updated>2019-08-26T08:25:00+00:00</updated>
<author>
<name>Beniamino Galvani</name>
<email>bgalvani@redhat.com</email>
</author>
<published>2019-08-19T13:32:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=c97e0ce30b8b9b118d47d0e02e6ebe7556e9f0c4'/>
<id>c97e0ce30b8b9b118d47d0e02e6ebe7556e9f0c4</id>
<content type='text'>
NM didn't support wpa-none for years because kernel drivers used to be
broken. Note that it wasn't even possible to *add* a connection with
wpa-none because it was rejected in nm_settings_add_connection_dbus().
Given that wpa-none is also deprecated in wpa_supplicant and is
considered insecure, drop altogether any reference to it.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
NM didn't support wpa-none for years because kernel drivers used to be
broken. Note that it wasn't even possible to *add* a connection with
wpa-none because it was rejected in nm_settings_add_connection_dbus().
Given that wpa-none is also deprecated in wpa_supplicant and is
considered insecure, drop altogether any reference to it.
</pre>
</div>
</content>
</entry>
<entry>
<title>libnm: fix parsing invalid "pvid" attribute in GVariant in _nm_utils_bridge_vlans_from_dbus()</title>
<updated>2019-08-02T09:48:35+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2019-08-02T09:29:42+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=7d603b7e35b5ef5c9f0a5b7b7f041fd98c716206'/>
<id>7d603b7e35b5ef5c9f0a5b7b7f041fd98c716206</id>
<content type='text'>
Complained by Coverity.

(cherry picked from commit 9f4302e1320081088d29db1f98c39fc4545267e3)
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Complained by Coverity.

(cherry picked from commit 9f4302e1320081088d29db1f98c39fc4545267e3)
</pre>
</div>
</content>
</entry>
<entry>
<title>libnm-core: add nm_utils_wifi_freq_to_band</title>
<updated>2019-07-29T09:00:24+00:00</updated>
<author>
<name>Andy Kling</name>
<email>andreas.kling@peiker-cee.de</email>
</author>
<published>2019-02-20T12:23:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=4dc375a068e7d117968ffdea0b598c1c4fc88084'/>
<id>4dc375a068e7d117968ffdea0b598c1c4fc88084</id>
<content type='text'>
allow to retrieve wifi band from frequency.

[lkundrak@v3.sk: formatting fixes, move the prototype to a private
header]
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
allow to retrieve wifi band from frequency.

[lkundrak@v3.sk: formatting fixes, move the prototype to a private
header]
</pre>
</div>
</content>
</entry>
<entry>
<title>libnm: accept %NULL for @name argument of nm_utils_is_valid_iface_name()</title>
<updated>2019-07-25T08:46:18+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2019-07-18T14:04:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=726192c185de74d799cf7bdce5caaa26a29e6b61'/>
<id>726192c185de74d799cf7bdce5caaa26a29e6b61</id>
<content type='text'>
Rejecting %NULL for a "is-a" function can be annoying. Of course, %NULL is
not a valid name. But it's sufficient that the function just returns
%FALSE in that case, and not assert against the input not being %NULL.

Asserting might be useful to catch bugs, but rejecting %NULL as input
is more cumbersome to the caller than helping with catching bugs.

Something similar was also recently done for nm_utils_is_uuid().
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Rejecting %NULL for a "is-a" function can be annoying. Of course, %NULL is
not a valid name. But it's sufficient that the function just returns
%FALSE in that case, and not assert against the input not being %NULL.

Asserting might be useful to catch bugs, but rejecting %NULL as input
is more cumbersome to the caller than helping with catching bugs.

Something similar was also recently done for nm_utils_is_uuid().
</pre>
</div>
</content>
</entry>
<entry>
<title>libnm,core: use nm_utils_clock_gettime_*() instead of clock_gettime()</title>
<updated>2019-07-23T10:19:33+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2019-07-23T09:52:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=be1727be1f93bf181c04e0a742196be154026905'/>
<id>be1727be1f93bf181c04e0a742196be154026905</id>
<content type='text'>
We usually want to combine the fields from "struct timespec" to
have one timestamp in either nanoseconds or milliseconds.

Use nm_utils_clock_gettime_*() util for that.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We usually want to combine the fields from "struct timespec" to
have one timestamp in either nanoseconds or milliseconds.

Use nm_utils_clock_gettime_*() util for that.
</pre>
</div>
</content>
</entry>
<entry>
<title>libnm: add nm_connection_to_dbus_full() with options argument</title>
<updated>2019-06-28T14:48:17+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2019-06-27T07:07:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=441dd1f3c837a0a280a2f127f8797807c2ebda22'/>
<id>441dd1f3c837a0a280a2f127f8797807c2ebda22</id>
<content type='text'>
No options are implemented yet.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
No options are implemented yet.
</pre>
</div>
</content>
</entry>
<entry>
<title>settings,libnm: move is-adhoc-wpa check to libnm</title>
<updated>2019-06-13T14:10:53+00:00</updated>
<author>
<name>Thomas Haller</name>
<email>thaller@redhat.com</email>
</author>
<published>2019-05-26T21:39:25+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/NetworkManager.git/commit/?id=ceaf64eee7c2e7e9cf596bbd601420557dd8feee'/>
<id>ceaf64eee7c2e7e9cf596bbd601420557dd8feee</id>
<content type='text'>
"nm-settings.c" is complex enough. Move this trivial helper function to libnm-core.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
"nm-settings.c" is complex enough. Move this trivial helper function to libnm-core.
</pre>
</div>
</content>
</entry>
</feed>
