Impossible to add new WiFi connections

After upgrading from 42.3 to 15.1 it is impossible to add new WiFi connection. When I try to establish a new connection by means of the plasma connection manager (type the password and press “Connect”) the SSID disappears forever. Somewhere on the net I found the advice to add the lines
[device]
wifi.scan-rand-mac-address=no

to the /etc/NetworkManager/NetworkManager.conf file. After adding these lines, the SID does not disappear, but the password is not saved, and it is not possible to connect the WLAN without adding the password for all users (i.e. saving it to /etc/NetworkManager/system-connections).

I think that the problem is in the connection between the plasma connection manager and the kwalletd5. This is a part of log (journalctl -u NetworkManager):
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0362] device (wlan0): Activation: starting connection ‘eralan’ (9deeda02-1234-4aff-b36c-217be87fa659)
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0611] settings-connection[0x5602cb527360,9deeda02-1234-4aff-b36c-217be87fa659]: write: successfully updated (keyfile:>
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0617] audit: op=“connection-add-activate” uuid=“9deeda02-1234-4aff-b36c-217be87fa659” name=“eralan” pid=3673 uid=1000>
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0832] device (wlan0): state change: disconnected -> prepare (reason ‘none’, sys-iface-state: ‘managed’)
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0840] manager: NetworkManager state is now CONNECTING
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0849] device (wlan0): state change: prepare -> config (reason ‘none’, sys-iface-state: ‘managed’)
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0853] device (wlan0): Activation: (wifi) access point ‘eralan’ has security, but secrets are required.
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0853] device (wlan0): state change: config -> need-auth (reason ‘none’, sys-iface-state: ‘managed’)
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <warn> [1566762879.0868] device (wlan0): No agents were available for this request.
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0868] device (wlan0): state change: need-auth -> failed (reason ‘no-secrets’, sys-iface-state: ‘managed’)
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0870] manager: NetworkManager state is now DISCONNECTED
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <warn> [1566762879.0873] device (wlan0): Activation: failed for connection ‘eralan’
Aug 25 22:54:39 asus-lashk.lashk NetworkManager[11119]: <info> [1566762879.0944] device (wlan0): state change: failed -> disconnected (reason ‘none’, sys-iface-state: ‘managed’)

Are you absolutely sure you have NetworkManager active? I have had mixed experience with installing Leap 15.1; on some occasions, the installation summary says NetworkManager but when I boot in I find that Wicked has been installed. So I would first check in YaST that NetworkManager is handling connections - also that DHCP is on rather than static IP.

Have you setup KWallet correctly?

NB:

kwallet-pam is not compatible with GnuPG keys, the KDE Wallet must use the standard blowfish encryption.

Yes, absolutely:

asus-lashk:~ # systemctl status NetworkManager
● NetworkManager.service - Network Manager
Loaded: loaded (/usr/lib/systemd/system/NetworkManager.service; enabled; ven>
Drop-In: /usr/lib/systemd/system/NetworkManager.service.d
└─NetworkManager-ovs.conf
Active: active (running) since Fri 2019-08-30 21:39:54 MSK; 2h 27min ago
Docs: man:NetworkManager(8)
Main PID: 18654 (NetworkManager)
Tasks: 4 (limit: 4915)
CGroup: /system.slice/NetworkManager.service
├─18654 /usr/sbin/NetworkManager --no-daemon
└─18801 /sbin/dhclient -d -q -sf /usr/lib/nm-dhcp-helper -pf /var/ru>

I did not change the setup since Leap 42.3. I have two wallets: a “default” one (encrypted) and a "alternative wallet for local passwords (unencrypted), which had always been used by the NetworkManager to save passwords.

Moreover, after the upgrade my computer does not connect any network that I saved for the user before the upgrade. I need to find the password in the wallet manually (by using KWalletManager, it opens both wallets without complaints) and change the record to one saved for everybody.

PS: I do not use auto-unlock. My unencrypted wallet had been always unlocked on the first demand from the NetworkManager, but know, as I understand, it does not receive such demand. If I unlock my wallets manually, it changes nothing.

  1. All KWallet wallets are encrypted – either with Blowfish or GnuPG – if you wish to inspect the effectiveness of Blowfish, please consult the writings of it’s inventor: Bruce Schneier <https://www.schneier.com/academic/blowfish/&gt;.
  2. There’s also this Wikipedia article: <https://en.wikipedia.org/wiki/Blowfish_(cipher)&gt;.
  3. If NetworkManager and other things such as KMail are to function correctly, the default Wallet has to have the name “kdewallet
    ” – it also has to use Blowfish if automatic unlocking at login is to function correctly … 1. If you’re worried about the security of Blowfish then, your additional
    Wallet – the one containing non-local passwords, can use GnuPG …

dcurtisfra, you seem to reply without reading my posts. Once again:

  1. My system of wallets worked perfectly
    on Leap 42.3. I have made no changes while upgrading to Leap 15.1. 1. The Plasma frontend for the NetworkManager on Leap 15.1 fails to write to or read from the wallets even if both wallets are unlocked
    by means of KWalletManager.

By the way, my “default” wallet is called “kdewallet”, and my second wallet (just for local passwords according to the settings of KWallet) is called “Local”. But I am sure, that this has no matter. I do not use the auto-unlock technology.

Then, you need to move the contents of your wallets around:

  • The contents of the default wallet need to be moved to a new GnuPG wallet suitably named for your non-local passwords.
  • The default wallet needs to be re-created with Blowfish encryption.
  • Your local passwords have to be moved to the default «kdewallet» wallet.

Yes, yes, I know, “it used to function as expected with Leap 42.3” but, the newer versions of KDE and Network Manager shipping with Leap 15.1 are more strict with respect to the KWallet environment …

  • There may be, deep in the Plasma Network Manager plasmoid configuration, something which will allow a wallet named something other than “kdewallet” to be used but, I’ve never found it …

Strangely, but the problem is just in the NetworkManager rather than in plasma-nm. I replaced NetworkManager-1.10.6 from the main repository by the version 1.18.2 from the repository home:lemmy04. Then I did “systemctl restart network” as a root. Now it works. It remembers passwords to my “Local” wallet, though it does not always identify the earlier saved networks with those I connect. I should study the situation further, but I think that the version 1.10.6 is buggy and should be replaced in the distribution.