Bug 340801 - Connection editor should not check "Use only for resources on this connection" for all vpn connections by default
Summary: Connection editor should not check "Use only for resources on this connection...
Status: RESOLVED FIXED
Alias: None
Product: plasma-nm
Classification: Plasma
Component: editor (show other bugs)
Version: 0.9.3.5
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: Lukáš Tinkl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-11-09 21:30 UTC by cocacooler
Modified: 2015-01-21 09:35 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 5.2.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description cocacooler 2014-11-09 21:30:12 UTC
For some reason plasma-nm connection editor checks the checkbox "ipv4->routes->use only for resources on this connection" by default for all vpn connections I import from .ovpn files. It should not do that because if you just do "openvpn --config filename.ovpn" it does not use it only for resources on that connection. To an average user who uses some vpn service for browsing internet this looks like the connection just does not work, and not everybody will check some advanced ipv4 settings.

So, if I import .ovpn file with plasma connection editor, do not change any settings and connect, route -n shows this (because of that checkbox):

# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         192.168.1.1     0.0.0.0         UG    1024   0        0 wlp2s0
10.8.0.1        10.8.0.5        255.255.255.255 UGH   1024   0        0 tun0
10.8.0.5        0.0.0.0         255.255.255.255 UH    0      0        0 tun0
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0 lo
127.0.0.0       127.0.0.1       255.0.0.0       UG    0      0        0 lo
SERVER_IP  192.168.1.1     255.255.255.255 UGH   10     0        0 wlp2s0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 wlp2s0

while if you just do "openvpn --config filename.ovpn", you get this:
# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
0.0.0.0         10.8.0.5        128.0.0.0       UG    0      0        0 tun0
0.0.0.0         192.168.1.1     0.0.0.0         UG    1024   0        0 wlp2s0
10.8.0.1        10.8.0.5        255.255.255.255 UGH   0      0        0 tun0
10.8.0.5        0.0.0.0         255.255.255.255 UH    0      0        0 tun0
127.0.0.0       0.0.0.0         255.0.0.0       U     0      0        0 lo
127.0.0.0       127.0.0.1       255.0.0.0       UG    0      0        0 lo
128.0.0.0       10.8.0.5        128.0.0.0       UG    0      0        0 tun0
SERVER_IP  192.168.1.1     255.255.255.255 UGH   0      0        0 wlp2s0
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 wlp2s0



Reproducible: Always
Comment 1 Jan Grulich 2014-11-12 11:49:41 UTC
Git commit c689cf204969ca8fca4a0c80553cab43dac5741a by Jan Grulich.
Committed on 12/11/2014 at 09:01.
Pushed by grulich into branch '0.9.3'.

Remove redirect-gateway tag from exported/imported config file

This is not used even in nm-connection-editor. Also if we are checking for this tag
which will never be present in exported OpenVPN connection from nm-connection-editor
we always set default-route in IPv4 config as true, which is not usually what users
want. I was talking with Dan Williams yesterday and NM-openvpn relies on autodetection
of the server user is connecting to. Also he plan to add functionality to this plugin
to set never-default automatically from this plugin.

M  +0    -16   vpn/openvpn/openvpn.cpp

http://commits.kde.org/plasma-nm/c689cf204969ca8fca4a0c80553cab43dac5741a
Comment 2 Jan Grulich 2014-11-12 12:03:39 UTC
Git commit 4da2b681d3c28d06cc4805ca8b047722cdd37280 by Jan Grulich.
Committed on 12/11/2014 at 12:02.
Pushed by grulich into branch 'master'.

Remove redirect-gateway tag from exported/imported config file

This is not used even in nm-connection-editor. Also if we are checking for this tag
which will never be present in exported OpenVPN connection from nm-connection-editor
we always set default-route in IPv4 config as true, which is not usually what users
want. I was talking with Dan Williams yesterday and NM-openvpn relies on autodetection
of the server user is connecting to. Also he plan to add functionality to this plugin
to set never-default automatically from this plugin.

M  +0    -12   vpn/openvpn/openvpn.cpp

http://commits.kde.org/plasma-nm/4da2b681d3c28d06cc4805ca8b047722cdd37280