Bug 405501 - plasma-nm is not compatible with NetworkManager 1.16's native WireGuard support
Summary: plasma-nm is not compatible with NetworkManager 1.16's native WireGuard support
Status: RESOLVED FIXED
Alias: None
Product: plasma-nm
Classification: Plasma
Component: general (show other bugs)
Version: master
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Bruce Anderson
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-03-15 18:26 UTC by K900
Modified: 2019-05-14 08:47 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description K900 2019-03-15 18:26:38 UTC
SUMMARY
The WireGuard connections are shown as wired connections, and are brought up automatically on login.

STEPS TO REPRODUCE
1. Install NetworkManager 1.16
2. nmcli connection import type wireguard file my-wg-conf.conf
3. Open plasma-nm

OBSERVED RESULT
WireGuard connection is treated as an Ethernet connection

EXPECTED RESULT
WireGuard connection should be treated as a WireGuard connection
Comment 1 Bruce Anderson 2019-03-17 00:34:52 UTC
This is going to take a while to fix because the configuration data for WireGuard connections has totally changed starting in the new version of NetworkManager. As a sidenote it appears that nm-connection-editor has not been updated to handle the change either.

In the meantime to make it so the WireGuard connections do not automatically start on login you can issue:
  nmcli connection modify <connection name> connection.autoconnect no

Then to start and stop the connection unfortunately it appears you will need to use:
  nmcli connection <up/down> <connection name>
because at least for me, the WireGuard connections don't show up on the popup menu to be connected using the plasma-nm interface.
Comment 2 K900 2019-03-17 05:42:58 UTC
Yeah, that's what I've been doing. Also, it turns out the autoconnect setting is actually enabled by nmcli by default for some reason, so that one isn't plasma-nm's fault. Anyway, I might just start hacking on it when I get the time (but please feel free to snipe me)
Comment 3 Jan Grulich 2019-05-14 08:47:46 UTC
Git commit 751f4da01b42dbb3dde8924b45c186174f7f5c1d by Jan Grulich.
Committed on 14/05/2019 at 08:47.
Pushed by grulich into branch 'master'.

Update WireGuard to match NetworkManager 1.16 interface

Summary:
In NetworkManager 1.16 handling of WireGuard interfaces was changed
from a VPN add-on to a core interface type with a different API. This
plasma-nm update is intended to match that change including (but not
limited to) moving address specification to the IPv4 and IPv6 tabs and
the ability to add multiple Peers to an interface.

Reviewers: jgrulich, #vdg, ngraham

Reviewed By: jgrulich, #vdg, ngraham

Subscribers: ngraham, plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D20930

M  +3    -0    applet/contents/ui/ConnectionItem.qml
M  +27   -0    kcm/kcm.cpp
M  +2    -0    kcm/qml/ConnectionItem.qml
M  +3    -0    kded/notification.cpp
M  +21   -2    kded/secretagent.cpp
M  +12   -1    libs/declarative/connectionicon.cpp
M  +10   -2    libs/declarative/networkstatus.cpp
M  +1    -0    libs/declarative/networkstatus.h
M  +8    -0    libs/editor/CMakeLists.txt
M  +15   -3    libs/editor/connectioneditorbase.cpp
M  +2    -2    libs/editor/settings/connectionwidget.cpp
R  +40   -84   libs/editor/settings/ui/wireguardinterfacewidget.ui [from: vpn/wireguard/wireguard.ui - 052% similarity]
A  +142  -0    libs/editor/settings/ui/wireguardpeerwidget.ui
A  +76   -0    libs/editor/settings/ui/wireguardtabwidget.ui
A  +639  -0    libs/editor/settings/wireguardinterfacewidget.cpp     [License: LGPL]
A  +59   -0    libs/editor/settings/wireguardinterfacewidget.h     [License: LGPL]
A  +375  -0    libs/editor/settings/wireguardpeerwidget.cpp     [License: LGPL]
C  +27   -25   libs/editor/settings/wireguardpeerwidget.h [from: vpn/wireguard/wireguardadvancedwidget.h - 052% similarity]
A  +178  -0    libs/editor/settings/wireguardtabwidget.cpp     [License: LGPL]
R  +22   -26   libs/editor/settings/wireguardtabwidget.h [from: vpn/wireguard/wireguardadvancedwidget.h - 050% similarity]
R  +3    -1    libs/editor/wireguardkeyvalidator.cpp [from: vpn/wireguard/wireguardkeyvalidator.cpp - 090% similarity]
R  +0    -0    libs/editor/wireguardkeyvalidator.h [from: vpn/wireguard/wireguardkeyvalidator.h - 100% similarity]
M  +10   -0    libs/models/creatableconnectionsmodel.cpp
M  +2    -3    libs/models/networkmodelitem.cpp
M  +7    -0    libs/uiutils.cpp
M  +1    -0    libs/uiutils.h
M  +0    -2    vpn/CMakeLists.txt
D  +0    -31   vpn/wireguard/CMakeLists.txt
D  +0    -3    vpn/wireguard/Messages.sh
D  +0    -48   vpn/wireguard/nm-wireguard-service.h
D  +0    -67   vpn/wireguard/plasmanetworkmanagement_wireguardui.desktop
D  +0    -426  vpn/wireguard/wireguard.cpp
D  +0    -41   vpn/wireguard/wireguard.h
D  +0    -252  vpn/wireguard/wireguardadvanced.ui
D  +0    -262  vpn/wireguard/wireguardadvancedwidget.cpp
D  +0    -55   vpn/wireguard/wireguardauth.cpp
D  +0    -43   vpn/wireguard/wireguardauth.h
D  +0    -31   vpn/wireguard/wireguardauth.ui
D  +0    -330  vpn/wireguard/wireguardwidget.cpp
D  +0    -59   vpn/wireguard/wireguardwidget.h

https://commits.kde.org/plasma-nm/751f4da01b42dbb3dde8924b45c186174f7f5c1d