
WoW. This was messier then it needs to be, but this does work. I have tried it with xubuntu and ubuntu mate successfully. As you know, the password area is grayed out.
I use PureVpn as a Virtual Private Network provider. But this works with any provider. This is a ppp (point-to-point) connection, which is different then /dev/tun. Tun rides over the top of a ppp connection.
1. The first step is to edit the configuration file. This will be found in /etc/NetworkManager/system-connections
My file looks like this:
[connection]
id=NameofConnection
uuid=YourUuid
type=vpn
autoconnect=false
permissions=
secondaries=
[vpn]
gateway=GatewayName
require-mppe=yes
user=Userid
refuse-chap=yes
refuse-eap=yes
refuse-pap=yes
password-flags=0
service-type=org.freedesktop.NetworkManager.pptp
[vpn-secrets]
password=YourPassword
[ipv4]
dns-search=
method=auto
[ipv6]
addr-gen-mode=stable-privacy
dns-search=
method=auto
Let’s try to break down what we changed. All the items I changed are bold like this. So I changed the connection name, gateway name or ip address, and userid.
Next you need to make sure that refuse-chap, refuse-eap, refuse-pap are all set to yes.
Normally the password-flags is set to 2. We need to set it to 0. This is important, so it does NOT reprompt.
Now add the section vpn-secrets with your password. Setting the flag to 0, and adding this section will save the password.
2. If not installed, install openvpn and the network-manager-openvpn.
sudo apt-get install openvpn network-manager-openvpn.
3. Now the tricky part. (see the problem above).
first let’s go the the directory and make a backup copy of org.freedesktop.NetworkManager.policy.
cd /usr/share/polkit-1/actions/
sudo cp org.freedesktop.NetworkManager.policy org.freedesktop.NetworkManager.policy.save # make a backup copy of the file first
sudo -H gedit /usr/share/polkit-1/actions/org.freedesktop.NetworkManager.policy
As it says in the article change the line the read:
<action id="org.freedesktop.NetworkManager.settings.modify.own"> . . . <allow_inactive>no</allow_inactive>
so that it says:
<allow_inactive>yes</allow_inactive>
4. Finally restart the Network Manager:
For us old guys:
sudo service network-manager restart
or
sudo systemctl restart network-manager
Related Articles
No user responded in this post