Bug 188489 - Complete VPNC support - support Always Ask secrets
Summary: Complete VPNC support - support Always Ask secrets
Status: RESOLVED FIXED
Alias: None
Product: Network Management
Classification: Miscellaneous
Component: Control Module (show other bugs)
Version: unspecified
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Will Stephenson
URL:
Keywords:
: 190443 198775 199253 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-03-30 17:01 UTC by Thomas David
Modified: 2009-11-17 19:11 UTC (History)
17 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas David 2009-03-30 17:01:46 UTC
Version:            (using KDE 4.2.1)
OS:                Linux
Installed from:    Ubuntu Packages

Distro: Kubuntu 9.04 Jaunty Beta (up to date)
plasma-widget-network-manager 0.0+svn930811-0ubuntu2

The network manager widget "forgets" configuration values of connections. After saving the connection and reopening it for editing, the lines are empty and checkboxes unset. This applies for wired, wireless and vpn connections.

Similar bugs:
https://bugs.launchpad.net/bugs/351390
https://bugs.launchpad.net/bugs/335777

Steps to reproduce:
1.) "Manage Connections"
2.) Add new VPNC VPN connection
3.) Fill in Gateway and Group name
4.) Save
5.) Edit the connection -> config values lost
or
1.) "Manage Connections"
2.) Add new Wired connection
3.) Tab "IP Adress"
4.) Method "Manual"
5.) Add Adress entry with Adress: 192.186.0.1 and Netmask prefix: 255.255.255.0
6.) Save
7.) Edit the connection -> config values lost

ProblemType: Bug
Architecture: i386
DistroRelease: Ubuntu 9.04
Package: plasma-widget-network-manager 0.0+svn930811-0ubuntu2
ProcEnviron:
 LANGUAGE=
 LANG=de_DE.UTF-8
 SHELL=/bin/bash
SourcePackage: plasma-widget-network-manager
Uname: Linux 2.6.28-11-generic i686
Comment 1 Martin Schlander 2009-04-16 12:36:22 UTC
I'm seeing this too.

Using mobile broadband I set the "Type" combobox to "3g (umts/hspa)", and whenever I return to re-edit the connection it's reverted to "Any".

Similarly the "MSCHAPv2" and "Allow BSD Compression" checkboxes in the PPP tab simply won't stay checked, no matter how many times I check them.
Comment 2 Kevin Funk 2009-04-23 16:12:32 UTC
*** Bug 190443 has been marked as a duplicate of this bug. ***
Comment 3 Manfred Moser 2009-05-12 05:11:33 UTC
I can confirm this bug for KDE 4.2.3 on Jaunty (packages from ppa).
Comment 4 Hans Überacher 2009-05-23 01:38:32 UTC
Same here. The only thing that's saved is the name of the connection.

Version: 0.0+svn966653-0ubuntu0.1
Comment 5 Todd 2009-06-04 03:05:43 UTC
I have this as well in KDE Trunk on opensuse 11.1.
Comment 6 Todd 2009-07-14 18:44:32 UTC
Still not working in KDE 4.3 RC2.
Comment 7 Will Stephenson 2009-07-23 00:46:21 UTC
*** Bug 199253 has been marked as a duplicate of this bug. ***
Comment 8 Will Stephenson 2009-07-23 00:48:48 UTC
Only the UI code for VPNC and the storage layer are implemented, none of the plumbing between the two.  Anyone want to step up and contribute a patch? I can give you a lot of tips how to go about it.
Comment 9 Will Stephenson 2009-07-23 09:16:13 UTC
*** Bug 198775 has been marked as a duplicate of this bug. ***
Comment 10 Will Stephenson 2009-08-03 08:54:51 UTC
SVN commit 1006190 by wstephens:

Implement loading vpnc settings.
CCBUG: 188489


 M  +1 -1      CMakeLists.txt  
 A             nm-vpnc-service.h   [License: GPL (v2+)]
 M  +1 -1      vpnc.cpp  
 M  +55 -11    vpncprop.ui  
 M  +100 -3    vpncwidget.cpp  
 M  +7 -1      vpncwidget.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1006190
Comment 11 Dominik Steenken 2009-08-03 10:44:26 UTC
cool. will this make it into the 4.3 release?
Comment 12 Sebastian Kügler 2009-08-03 11:30:03 UTC
The KDE networkmanager code is not part of the release, and 4.3 got feature-frozen more than two months ago. ... :)
Comment 13 Will Stephenson 2009-08-03 12:44:58 UTC
SVN commit 1006258 by wstephens:

Implement writing VPNC connection settings.

Please test!  I have no way of testing this code with a real VPNC
service.  It is only correct as far as I can see compared with the gnome
vpnc plugin.

BUG: 188489



 M  +10 -4     vpncprop.ui  
 M  +102 -6    vpncwidget.cpp  
 M  +3 -0      vpncwidget.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1006258
Comment 14 Will Stephenson 2009-08-03 12:47:55 UTC
Dominik: this code uses KDE 4.3 but is not part of KDE 4.3.  As Sebas says it is outside the release cycle.  However I have notified the distributions that I know are using NetworkManager to package this so it is available alongside 4.3.
Comment 15 Christian Trippe 2009-08-06 17:41:40 UTC
I am using openSUSE 11.1 with 

NetworkManager-vpnc-kde4-0.9.svn1007025-83.1
NetworkManager-kde4-libs-0.9.svn1007025-83.1
NetworkManager-kde4-0.9.svn1007025-83.1
NetworkManager-kde4-debuginfo-0.9.svn1007025-83.1
NetworkManager-kde4-lang-0.9.svn1007025-83.1

When I try to connenct either knetworkmanager crashes, see 
http://bugzilla.novell.com/show_bug.cgi?id=528539

or it does not connect. Here is the NetworkManager log from a failed connection:

Aug  6 17:21:57 asterix NetworkManager: <info>  Starting VPN service 'org.freedesktop.NetworkManager.vpnc'...
Aug  6 17:21:57 asterix NetworkManager: <info>  VPN service 'org.freedesktop.NetworkManager.vpnc' started (org.freedesktop.NetworkManager.vpnc), PID 11984
Aug  6 17:21:57 asterix NetworkManager: <info>  VPN service 'org.freedesktop.NetworkManager.vpnc' just appeared, activating connections
Aug  6 17:21:57 asterix NetworkManager: <info>  VPN plugin state changed: 3
Aug  6 17:21:57 asterix NetworkManager: <info>  VPN connection 'uni-wuppertal-extern' (Connect) reply received.
Aug  6 17:21:57 asterix NetworkManager: <WARN>  nm_vpn_connection_connect_cb(): VPN connection 'uni-wuppertal-extern' failed to connect: 'property 'ipsec-secret-type' invalid or not supported'.
Aug  6 17:21:57 asterix NetworkManager: <WARN>  connection_state_changed(): Could not process the request because no VPN connection was active.
Aug  6 17:21:57 asterix NetworkManager: <debug> [1249572117.455895] run_netconfig(): Spawning '/sbin/netconfig modify --service NetworkManager'
Aug  6 17:21:57 asterix NetworkManager: <debug> [1249572117.471039] write_to_netconfig(): Writing to netconfig: INTERFACE='eth1'
Aug  6 17:21:57 asterix NetworkManager: <debug> [1249572117.471261] write_to_netconfig(): Writing to netconfig: DNSSERVERS='192.168.178.1'
Aug  6 17:21:57 asterix NetworkManager: <info>  Clearing nscd hosts cache.
Aug  6 17:21:57 asterix NetworkManager: <info>  Policy set 'wlan-netz' (eth1) as default for routing and DNS.
Aug  6 17:22:09 asterix NetworkManager: <debug> [1249572129.464191] ensure_killed(): waiting for vpn service pid 11984 to exit
Aug  6 17:22:09 asterix NetworkManager: <debug> [1249572129.464361] ensure_killed(): vpn service pid 11984 cleaned up
Comment 16 Will Stephenson 2009-08-06 18:46:48 UTC
Please attach the dbus connection settings as described here: http://userbase.kde.org/NetworkManagement#It.27s_All_KDE.27s_Fault.21
Comment 17 Christian Trippe 2009-08-06 19:14:56 UTC
qdbus --system --literal org.freedesktop.NetworkManagerUserSettings /org/freedesktop/NetworkManagerSettings/0 org.freedesktop.NetworkManagerSettings.Connection.GetSettings

[Argument: 
a{sa{sv}} {"802-11-wireless" = [Argument: a{sv} {"mode" = [Variant(QString): "infrastructure"], 
"security" = [Variant(QString): "802-11-wireless-security"], 
"seen-bssids" = [Variant(QStringList): {"00:04:0E:4D:A5:EB"}], 
"ssid" = [Variant(QByteArray): {119, 108, 97, 110, 45, 110, 101, 116, 122}]}], 
"802-11-wireless-security" = [Argument: a{sv} {"key-mgmt" = [Variant(QString): "wpa-psk"]}], 
"connection" = [Argument: a{sv} {"autoconnect" = [Variant(bool): true], 
"id" = [Variant(QString): "wlan-netz"], 
"timestamp" = [Variant(uint): 1249572107], 
"type" = [Variant(QString): "802-11-wireless"], 
"uuid" = [Variant(QString): "{9d8c5c19-d791-4c04-b827-4549bd0aecec}"]}]}]
Comment 18 Christian Trippe 2009-08-06 19:24:19 UTC
Sorry the above was for the wrong connection. Now the one for the vpn connection:

qdbus --system --literal org.freedesktop.NetworkManagerUserSettings /org/freedesktop/NetworkManagerSettings/1 org.freedesktop.NetworkManagerSettings.Connection.GetSettings

[Argument: 
a{sa{sv}} {"connection" = [Argument: a{sv} {"autoconnect" = [Variant(bool): false], 
"id" = [Variant(QString): "uni-wuppertal-extern"], 
"type" = [Variant(QString): "vpn"], 
"uuid" = [Variant(QString): "{09bc97a7-222b-4df9-9106-40d75b976d62}"]}], 
"vpn" = [Argument: a{sv} {"data" = [Variant: [Argument: a{ss} {"DPD idle timeout (our side)" = "0", 
"IPSec ID" = "***", 
"IPSec gateway" = "vpn-extern.uni-wuppertal.de", 
"NAT Traversal Mode" = "natt", 
"Xauth username" = "*****", 
"ipsec-secret-type" = "save", 
"xauth-password-type" = "save"}]], 
"secrets" = [Variant: [Argument: a{ss} {}]], 
"service-type" = [Variant(QString): "org.freedesktop.NetworkManager.vpnc"], 
"user-name" = [Variant(QString): "*****"]}]}]
Comment 19 Franz 2009-08-15 00:44:12 UTC
Hello,

I just tried vpnc with svn 1011465, and although connection data are saved, secrets are not. In kwallet, there's a Network Management > Maps > {...} > VpnSecrets key, but it has no value.

If you need more information / testing, just ask
Comment 20 Will Stephenson 2009-08-30 12:00:23 UTC
*** Bug 204596 has been marked as a duplicate of this bug. ***
Comment 21 Will Stephenson 2009-09-11 18:38:39 UTC
SVN commit 1022385 by wstephens:

Fix the logic for writing VPNC connection secrets.
BUG: 188489


 M  +2 -2      vpncwidget.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1022385
Comment 22 Franz 2009-09-13 22:19:37 UTC
Hi,

i've tried svn 1022899, and saving passwords works great. However if i change the combobox to "Always ask", it won't ask for a password and fails to connect.
Comment 23 Christian Trippe 2009-09-16 18:55:54 UTC
vpnc with knm4 still does not work for me with NetworkManager-vpnc-kde4-0.9.svn1023237-107.1 on openSUSE 11.1

NetworkManager log

Sep 16 18:48:27 asterix NetworkManager: <info>  Starting VPN service 'org.freedesktop.NetworkManager.vpnc'...
Sep 16 18:48:27 asterix NetworkManager: <info>  VPN service 'org.freedesktop.NetworkManager.vpnc' started (org.freedesktop.NetworkManager.vpnc), PID 5547
Sep 16 18:48:27 asterix NetworkManager: <info>  VPN service 'org.freedesktop.NetworkManager.vpnc' just appeared, activating connections
Sep 16 18:48:27 asterix NetworkManager: <info>  VPN plugin state changed: 3
Sep 16 18:48:27 asterix NetworkManager: <info>  VPN connection 'uni-wuppertal-extern' (Connect) reply received.
Sep 16 18:48:27 asterix NetworkManager: <WARN>  nm_vpn_connection_connect_cb(): VPN connection 'uni-wuppertal-extern' failed to connect: 'property 'ipsec-secret-type' invalid or not supported'.
Sep 16 18:48:27 asterix NetworkManager: <WARN>  connection_state_changed(): Could not process the request because no VPN connection was active.
Sep 16 18:48:27 asterix NetworkManager: <debug> [1253119707.731994] run_netconfig(): Spawning '/sbin/netconfig modify --service NetworkManager'
Sep 16 18:48:27 asterix NetworkManager: <debug> [1253119707.760376] write_to_netconfig(): Writing to netconfig: INTERFACE='eth1'
Sep 16 18:48:27 asterix NetworkManager: <debug> [1253119707.760631] write_to_netconfig(): Writing to netconfig: DNSSERVERS='192.168.178.1'
Sep 16 18:48:27 asterix NetworkManager: <info>  Clearing nscd hosts cache.
Sep 16 18:48:27 asterix NetworkManager: <info>  Policy set 'wlan-netz' (eth1) as default for routing and DNS.
Sep 16 18:48:39 asterix NetworkManager: <debug> [1253119719.740091] ensure_killed(): waiting for vpn service pid 5547 to exit
Sep 16 18:48:39 asterix NetworkManager: <debug> [1253119719.740555] ensure_killed(): vpn service pid 5547 cleaned up

 qdbus --system --literal org.freedesktop.NetworkManagerUserSettings /org/freedesktop/NetworkManagerSettings/3 org.freedesktop.NetworkManagerSettings.Connection.GetSettings

[Argument: 
a{sa{sv}} {"connection" = [Argument: a{sv} {"autoconnect" = [Variant(bool): false], 
"id" = [Variant(QString): "uni-wuppertal-extern"], 
"type" = [Variant(QString): "vpn"], 
"uuid" = [Variant(QString): "cfc70d73-1591-4dd7-b52b-be7952368786"]}], 
"vpn" = [Argument: a{sv} {"data" = [Variant: [Argument: a{ss} {"IPSec ID" = "****", 
"IPSec gateway" = "vpn-extern.uni-wuppertal.de", 
"Xauth username" = "***", 
"ipsec-secret-type" = "save", 
"xauth-password-type" = "save"}]], 
"secrets" = [Variant: [Argument: a{ss} {}]], 
"service-type" = [Variant(QString): "org.freedesktop.NetworkManager.vpnc"], 
"user-name" = [Variant(QString): "***"]}]}]
Comment 24 Christian Trippe 2009-11-10 21:19:44 UTC
(In reply to comment #23)
> vpnc with knm4 still does not work for me with
> NetworkManager-vpnc-kde4-0.9.svn1023237-107.1 on openSUSE 11.1
> 

JFYI: It works for me now with:
NetworkManager-vpnc-kde4-0.9.svn1043876-1.1.1.i586 on openSUSE 11.2
Comment 25 Will Stephenson 2009-11-17 12:40:20 UTC
I am working on showing the password dialog for Always Ask but it's difficult.
Comment 26 Will Stephenson 2009-11-17 19:11:24 UTC
Sorry, please use #204596 for Always Ask issues.