Bug 451137

Summary: connection.interface-name: 'New wireguard connection': interface name contains an invalid character
Product: [Plasma] plasmashell Reporter: Artyom <bugs.kde.org>
Component: Networking in generalAssignee: Plasma Bugs List <plasma-bugs-null>
Status: CONFIRMED ---    
Severity: normal CC: ddomenichelli, jgrulich, lamarque, lukas.tinkl, neromaverick, nicolas.fella, uwu
Priority: NOR    
Version First Reported In: master   
Target Milestone: 1.0   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: the error
default name

Description Artyom 2022-03-04 18:27:00 UTC
Created attachment 147277 [details]
the error

SUMMARY
connection.interface-name: 'New wireguard connection': interface name contains an invalid character


STEPS TO REPRODUCE
1. create wireguard connection, do not change the name (default is "New wireguard connection")
2. save

OBSERVED RESULT
connection is not added

EXPECTED RESULT
connection is not added

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: cpe:/o:opensuse:tumbleweed:20220302
KDE Plasma Version: 5.24.2
KDE Frameworks Version: 5.91
Qt Version: 5.15.2

ADDITIONAL INFORMATION
do not create an interface with the same name?
Comment 1 Artyom 2022-03-04 18:27:36 UTC
Created attachment 147278 [details]
default name
Comment 2 Daniele E. Domenichelli 2022-08-02 11:41:59 UTC
I can confirm this. A simple fix would be to change default name to something that will be accepted. Still, there should be some check before closing the dialog and losing all the configuration in case the user sets an invalid name for the connection (or other invalid parameters). Also the notification that pops up is easy to miss, I had to repeat the process 3 times before noticing it.
Comment 3 neromaverick 2022-08-05 07:30:03 UTC
The "Connection Name" field needs to be an acceptable Wireguard interface name. So using "wg0" as the connection name will succeed in creating the interface. 

IMO this is a poor GUI implementation. Closing the dialog and having to restart on a failure aside, the "Connection name" field should be reserved for a personal arbitrary name for this connection.

If Wireguard requires a device name such as wg0, wg1, etc. Then an additional field needs to be added to specify which wg interface number this connection uses. Either that, or automatically set the interface name, taking it out of the users hands.

I want to note, this is not a typical behavior of how connection configurations work. When I name my LAN "Laptop NIC", I don't see ...8: 'Laptop NIC': <BROADCAST,MULTICAST,U... As my interface name when I run 'ip a'
Comment 4 Ben Cooksley 2024-12-23 18:23:38 UTC
Bulk transfer as requested in T17796