Network routing issue

Sam sam.shabake at samic.org
Fri Jul 1 18:55:20 PDT 2022


Hello,

I'm trying to use OpenConnect (v8.05-1) and I can successfully connect 
to the VPN (on Linux Mint 20.3). But network routing doesn't work!
I use the vpnc-script from 
https://gitlab.com/openconnect/vpnc-scripts/raw/master/vpnc-script like 
this:
sudo openconnect vpn.thecompany.com 
--script=/usr/share/vpnc-scripts/vpnc-script

The only way that I can make it work is to do this manually:

sudo ip route del default via 192.168.0.1
sudo ip route add default via 10.100.220.210

But then the problem is if the VPN disconnects, I have to restart the 
computer to get the network back!


Here is the "ip route" before connecting:

default via 192.168.0.1 dev enp4s0
10.0.3.0/24 dev lxcbr0 proto kernel scope link src 10.0.3.1 linkdown
169.254.0.0/16 dev enp4s0 scope link metric 1000
192.168.0.0/24 dev enp4s0 proto kernel scope link src 192.168.0.130 
metric 100

_________________________________________


Here is the "ip route" after connecting:

default via 192.168.0.1 dev enp4s0
10.0.0.0/22 dev tun0 scope link
10.0.3.0/24 dev lxcbr0 proto kernel scope link src 10.0.3.1 linkdown
10.0.16.0/20 dev tun0 scope link
10.30.0.0/16 dev tun0 scope link
10.100.0.0/16 dev tun0 scope link
10.100.250.50 dev tun0 scope link
10.105.0.0/16 dev tun0 scope link
10.105.201.0/24 dev tun0 scope link
10.108.0.0/16 dev tun0 scope link
10.150.0.0/16 dev tun0 scope link
10.155.0.0/16 dev tun0 scope link
10.190.0.0/20 dev tun0 scope link
10.190.16.0/20 dev tun0 scope link
10.190.32.0/20 dev tun0 scope link
10.191.0.0/20 dev tun0 scope link
10.191.16.0/20 dev tun0 scope link
10.191.32.0/20 dev tun0 scope link
13.49.116.92 dev tun0 scope link
34.216.145.217 dev tun0 scope link
34.217.235.168 dev tun0 scope link
34.219.114.199 dev tun0 scope link
35.161.126.55 dev tun0 scope link
44.232.133.0/24 dev tun0 scope link
44.238.125.119 dev tun0 scope link
44.240.67.157 dev tun0 scope link
52.11.6.69 dev tun0 scope link
52.27.60.16 dev tun0 scope link
52.37.31.219 dev tun0 scope link
52.37.48.136 dev tun0 scope link
52.41.79.174 dev tun0 scope link
52.88.23.55 dev tun0 scope link
54.68.247.82 dev tun0 scope link
54.69.17.252 dev tun0 scope link
54.200.179.53 dev tun0 scope link
54.201.236.85 dev tun0 scope link
54.212.73.86 dev tun0 scope link
54.218.181.50 dev tun0 scope link
169.254.0.0/16 dev enp4s0 scope link metric 1000
172.25.0.0/20 dev tun0 scope link
172.26.0.0/20 dev tun0 scope link
172.26.16.0/20 dev tun0 scope link
192.168.0.0/24 dev enp4s0 proto kernel scope link src 192.168.0.130 
metric 100
192.168.254.0/24 dev tun0 scope link
209.37.189.242 via 192.168.0.1 dev enp4s0

Any help is appreciated.




More information about the openconnect-devel mailing list