Re: network-manager: doesn't show nor autoconnect to hidden wifi

2019-07-17 Thread Jiri Novak
Hi,
after more discussion with thaller on NM, there actually seems to be a
bug, as the wifi is properly detected at one point and a while later it
is not in the cache - which seems might not been happening on the
version shipped with debian 9 and therefore would work even without
hidden=true (this is from log where i run it without that option)


Jul 17 10:10:49 LX-novak NetworkManager[1335]:  [1563351049.8905]
device[0x55f38610a480] (wlan0): matched hidden AP D6:CA:6D:XX:XX:XX =>
"TH-W0200-management"
Jul 17 10:10:49 LX-novak NetworkManager[1335]:  [1563351049.8905]
dbus-object[0x55f386103f10]: export:
"/org/freedesktop/NetworkManager/AccessPoint/13"
Jul 17 10:10:49 LX-novak NetworkManager[1335]:  [1563351049.8908]
device[0x55f38610a480] (wlan0): wifi-ap: added   D6:CA:6D:XX:XX:XX
"TH-W0200-management"   [ a  36  37% P W: R:0188 ]   0s
sup:/12 [nm:/13]

Jul 17 10:10:49 LX-novak NetworkManager[1335]:  [1563351049.9727]
device[0x55f38610a480] (wlan0): wifi-ap: updated D6:CA:6D:6D:13:B4
(none)  [ a  36  37% P W: R:0188 ]   0s
sup:/12 [nm:/13]


JN


On 7/17/19 12:03 PM, Michael Biebl wrote:
> Am 17.07.19 um 10:48 schrieb Jiri Novak:
>> Managed to debug it with someone else at #nm irc.
>>
>> the issue was that the wifi.hidden=yes works only on commandline, in
>> config file it needs hidden=true.
>> seems this version strictly needs this configured, the version shipped
>> with debian 9 did autoconnect even without hidden=true, now it needs to
>> be added with "nmcli connection modify uuid wifi.hidden=yes" or adding
>> line in the profile file under
>>
>> [wifi]
>> hidden=true
> Looping in the networkmanager mailing list.
>
> Not sure if this new behaviour of having to explicitly set hidden=true
> is deliberate or considered a bug (given that it breaks existing
> connection profiles)
>
>




signature.asc
Description: OpenPGP digital signature
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: network-manager: doesn't show nor autoconnect to hidden wifi

2019-07-17 Thread Michael Biebl
Am 17.07.19 um 10:48 schrieb Jiri Novak:
> Managed to debug it with someone else at #nm irc.
> 
> the issue was that the wifi.hidden=yes works only on commandline, in
> config file it needs hidden=true.
> seems this version strictly needs this configured, the version shipped
> with debian 9 did autoconnect even without hidden=true, now it needs to
> be added with "nmcli connection modify uuid wifi.hidden=yes" or adding
> line in the profile file under
> 
> [wifi]
> hidden=true

Looping in the networkmanager mailing list.

Not sure if this new behaviour of having to explicitly set hidden=true
is deliberate or considered a bug (given that it breaks existing
connection profiles)


-- 
Why is it that all of the instruments seeking intelligent life in the
universe are pointed away from Earth?



signature.asc
Description: OpenPGP digital signature
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


Re: [PATCH] vpn-manager: respect NM_VPN_PLUGIN_DIR

2019-07-17 Thread Thomas Haller via networkmanager-list
On Wed, 2019-07-17 at 11:46 +0200, Jelle Licht wrote:
> From: Tomáš Čech 

Hi,


This was not done intentionally (so far).

Clients (nm-applet, nmcli) may load the client parts of the VPN plugins
(the libnm.plugin setting from the .name file).
That's useful to show the GTK configuration dialog or implement `nmcli
connection import`.
These applications run in the user's context, and it makes sense that a
user compiles a VPN plugin that he/she installs in a private patch
(setting NM_VPN_PLUGIN_DIR). It's their choice.

But the daemon runs as root, so setting NM_VPN_PLUGIN_DIR requires you
to become root, to restart the daemon, and to set the environment
variable (in the systemd service file). At that point, you could just
as well copy the .name file to /usr/lib/NetworkManager/VPN. Why is that
not sufficient?



 
> + file = g_file_new_for_path (conf_dir_user);
> + priv->monitor_etc = g_file_monitor_directory (file,
> G_FILE_MONITOR_NONE, NULL, NULL);
> + g_object_unref (file);
> + if (priv->monitor_etc) {

btw, you cannot overwrite the existing monitor_etc and monitor_id_etc
fields. It would require new ones...



best,
Thomas


signature.asc
Description: This is a digitally signed message part
___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list


[PATCH] vpn-manager: respect NM_VPN_PLUGIN_DIR

2019-07-17 Thread Jelle Licht
From: Tomáš Čech 

---
 src/vpn/nm-vpn-manager.c | 14 ++
 1 file changed, 14 insertions(+)

diff --git a/src/vpn/nm-vpn-manager.c b/src/vpn/nm-vpn-manager.c
index 36043c935..e73ccac47 100644
--- a/src/vpn/nm-vpn-manager.c
+++ b/src/vpn/nm-vpn-manager.c
@@ -220,6 +220,7 @@ nm_vpn_manager_init (NMVpnManager *self)
GSList *infos, *info;
const char *conf_dir_etc = _nm_vpn_plugin_info_get_default_dir_etc ();
const char *conf_dir_lib = _nm_vpn_plugin_info_get_default_dir_lib ();
+   const char *conf_dir_user = _nm_vpn_plugin_info_get_default_dir_user ();
 
/* Watch the VPN directory for changes */
file = g_file_new_for_path (conf_dir_lib);
@@ -238,6 +239,14 @@ nm_vpn_manager_init (NMVpnManager *self)
 G_CALLBACK 
(vpn_dir_changed), self);
}
 
+   file = g_file_new_for_path (conf_dir_user);
+   priv->monitor_etc = g_file_monitor_directory (file, 
G_FILE_MONITOR_NONE, NULL, NULL);
+   g_object_unref (file);
+   if (priv->monitor_etc) {
+   priv->monitor_id_etc = g_signal_connect (priv->monitor_etc, 
"changed",
+G_CALLBACK 
(vpn_dir_changed), self);
+   }
+
/* first read conf_dir_lib. The name files are not really user 
configuration, but
 * plugin configuration. Hence we expect ~newer~ plugins to install 
their files
 * in /usr/lib/NetworkManager. We want to prefer those files.
@@ -252,6 +261,11 @@ nm_vpn_manager_init (NMVpnManager *self)
try_add_plugin (self, info->data);
g_slist_free_full (infos, g_object_unref);
 
+   infos = _nm_vpn_plugin_info_list_load_dir (conf_dir_user, TRUE, 0, 
NULL, NULL);
+   for (info = infos; info; info = info->next)
+   try_add_plugin (self, info->data);
+   g_slist_free_full (infos, g_object_unref);
+
priv->active_services = g_hash_table_new_full (nm_str_hash, 
g_str_equal, g_free, NULL);
 }
 
-- 
2.22.0

___
networkmanager-list mailing list
networkmanager-list@gnome.org
https://mail.gnome.org/mailman/listinfo/networkmanager-list