Quantcast
Channel: Active questions tagged openconnect - Unix & Linux Stack Exchange
Viewing all articles
Browse latest Browse all 60

OpenWRT - Openconnect VPN on isolated SSID

$
0
0

I'm trying to add a third SSID to my OpenWRT router which only connects users to an Openconnect VPN network.

The router has two existing SSIDs which connect to the LAN+internet on 2.4 and 5.0 GHz antenna arrays. I'm able to connect directly to the VPN network via NetworkManager on my Linux PC.

When connecting to my new SSID, I get an IP but no internet connection. I'm also unsure whether the VPN connection is succeeding or not.

I followed the instructions at https://github.com/openwrt/packages/tree/master/net/openconnect as well as tried to understand what's going on in this question but with no success.

Below are the additions to the config files I made:

/etc/config/network:

# VPN SSID Interface
config interface 'vpn'
    option proto 'static'
    option ipaddr '192.168.34.1'
    option netmask '255.255.255.0'
    option ipv6 '0'

# Openconnect
config interface 'myvpn'
    option proto 'openconnect'
    option interface 'wan' # Is this right? Was on github's openconnect example
    option server 'myvpn.com'
    option port '4443'
    option username 'user'
    option password 'password'
    #option serverhash '' # Don't need this?
    option defaultroute '0'
    option authgroup 'DEFAULT'
    option token_mode 'rsa'
    option token_secret 'http://127.0.0.1/securid/ctf?ctfData=...'
    option ipv6 '0'

/etc/config/wireless

config wifi-iface
    option device 'radio1' # My 5.0 GHz antenna
    option network 'vpn'
    option mode 'ap'
    option ssid 'myVPN'
    option hidden '1'
    option encryption 'psk2'
    option key 'some super secret key'

/etc/config/dhcp

config dhcp 'vpn'
    option interface 'vpn'
    option start '100'
    option limit '150'
    option leasetime '12h'

/etc/config/firewall

config zone
    option name     vpn
    list   network      'vpn'
    option input        ACCEPT
    option output       ACCEPT
    option forward      ACCEPT

config zone
    option name     myvpn
    list   network      'myvpn'
    option input        ACCEPT
    option output       ACCEPT
    option forward      ACCEPT

config forwarding
    option src      vpn
    option dest     myvpn

I also restart all of the components:

# /etc/init.d/network restart
# /etc/init.d/dnsmasq restart
# /etc/init.d/firewall restart
# wifi
# ifup myvpn

I do get the following messages when running # /etc/init.d/firewall restart:

Warning: Section @zone[2] (myvpn) cannot resolve device of network 'myvpn'
Warning: Section @zone[2] (myvpn) has no device, network, subnet or extra options

Viewing all articles
Browse latest Browse all 60

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>