For some reason I am facing troubles routing to LAN behind the router from OpenVPN server.
I am sorry if this has been asked, I have tried searching for topic without a satisfactory results.
My aim is to maintain a network behind Router Asus RT-AC86U, running Merlin 384.15, remotely from my RemoteServer.
On the Router, I have configured an OpenVPN client, IP 10.8.51.6, that connects onto my RemoteServer, IP 10.8.51.1. Note setting up OpenVPN server on the Router is not an option as it does not receive a public ip.
From RemoteServer, I can ping the Router, I can ssh to the Router, but I cannot even ping any LAN machine (lets say 192.168.51.12) on Router's LAN 192.168.51.0. (Ping inside LAN works fine.)
On RemoteServer I have:
I have also attempted to configure firewall:
On Router:
I have disabled ipv4 and ipv6 firewalls in GUI / Firewall / General
Established OpenVPN connection details as printed in System Log are:
I have even tried to set some explicit rules in iptables:
routes on the Router:
Any guess on what I may be missing?
Thanks in advance.
I am sorry if this has been asked, I have tried searching for topic without a satisfactory results.
My aim is to maintain a network behind Router Asus RT-AC86U, running Merlin 384.15, remotely from my RemoteServer.
On the Router, I have configured an OpenVPN client, IP 10.8.51.6, that connects onto my RemoteServer, IP 10.8.51.1. Note setting up OpenVPN server on the Router is not an option as it does not receive a public ip.
From RemoteServer, I can ping the Router, I can ssh to the Router, but I cannot even ping any LAN machine (lets say 192.168.51.12) on Router's LAN 192.168.51.0. (Ping inside LAN works fine.)
On RemoteServer I have:
Code:
root@RemoteServer:/etc/openvpn# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.0.1 0.0.0.0 UG 100 0 0 enp1s0
10.8.51.0 * 255.255.255.0 U 0 0 0 tun1
link-local * 255.255.0.0 U 1000 0 0 tun1
192.168.0.0 * 255.255.255.0 U 100 0 0 enp1s0
192.168.51.0 10.8.51.2 255.255.255.0 UG 0 0 0 tun1
I have also attempted to configure firewall:
Code:
root@RemoteServer:/etc/openvpn# ufw status
Status: active
To Action From
-- ------ ----
1194/udp ALLOW Anywhere
Anywhere ALLOW 10.8.51.6
10.8.51.6 ALLOW Anywhere
1194/udp (v6) ALLOW Anywhere (v6)
On Router:
I have disabled ipv4 and ipv6 firewalls in GUI / Firewall / General
Established OpenVPN connection details as printed in System Log are:
Code:
Apr 30 00:02:52 rc_service: httpd 991:notify_rc start_vpnclient1
Apr 30 00:02:52 ovpn-client1[1869]: OpenVPN 2.4.8 arm-buildroot-linux-gnueabi [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [MH/PKTINFO] [AEAD] built on Feb 8 2020
Apr 30 00:02:52 ovpn-client1[1869]: library versions: OpenSSL 1.1.1d 10 Sep 2019, LZO 2.08
Apr 30 00:02:52 ovpn-client1[1870]: NOTE: the current --script-security setting may allow this configuration to call user-defined scripts
Apr 30 00:02:52 ovpn-client1[1870]: Outgoing Control Channel Authentication: Using 512 bit message hash 'SHA512' for HMAC authentication
Apr 30 00:02:52 ovpn-client1[1870]: Incoming Control Channel Authentication: Using 512 bit message hash 'SHA512' for HMAC authentication
Apr 30 00:02:52 ovpn-client1[1870]: TCP/UDP: Preserving recently used remote address: [AF_INET]xx.xx.xx.xx:1194
Apr 30 00:02:52 ovpn-client1[1870]: Socket Buffers: R=[524288->524288] S=[524288->524288]
Apr 30 00:02:52 ovpn-client1[1870]: UDP link local: (not bound)
Apr 30 00:02:52 ovpn-client1[1870]: UDP link remote: [AF_INET]xx.xx.xx.xx:1194
Apr 30 00:02:52 ovpn-client1[1870]: TLS: Initial packet from [AF_INET]xx.xx.xx.xx:1194, sid=6d19cea7 bf8a9784
Apr 30 00:02:52 ovpn-client1[1870]: VERIFY OK: depth=1, C=UK, ST=xxx, L=xxx, O=xxx, OU=xxx, CN=xxx CA, name=RemoteServer, emailAddress=xxx
Apr 30 00:02:52 ovpn-client1[1870]: VERIFY KU OK
Apr 30 00:02:52 ovpn-client1[1870]: Validating certificate extended key usage
Apr 30 00:02:52 ovpn-client1[1870]: ++ Certificate has EKU (str) TLS Web Server Authentication, expects TLS Web Server Authentication
Apr 30 00:02:52 ovpn-client1[1870]: VERIFY EKU OK
Apr 30 00:02:52 ovpn-client1[1870]: VERIFY OK: depth=0, C=UK, ST=xxx, L=xxx, O=xxx, OU=jiri, CN=xxx, name=xxx, emailAddress=xxx
Apr 30 00:02:52 ovpn-client1[1870]: Control Channel: TLSv1.2, cipher TLSv1.2 DHE-RSA-AES256-GCM-SHA384, 2048 bit RSA
Apr 30 00:02:52 ovpn-client1[1870]: [Remote_vpn] Peer Connection Initiated with [AF_INET]xx.xx.xx.xx:1194
Apr 30 00:02:53 ovpn-client1[1870]: SENT CONTROL [Remote_vpn]: 'PUSH_REQUEST' (status=1)
Apr 30 00:02:53 ovpn-client1[1870]: PUSH: Received control message: 'PUSH_REPLY,route-gateway 10.8.51.1,topology subnet,ping 10,ping-restart 120,ifconfig 10.8.51.6 255.255.255.0'
Apr 30 00:02:53 ovpn-client1[1870]: OPTIONS IMPORT: timers and/or timeouts modified
Apr 30 00:02:53 ovpn-client1[1870]: OPTIONS IMPORT: --ifconfig/up options modified
Apr 30 00:02:53 ovpn-client1[1870]: OPTIONS IMPORT: route-related options modified
Apr 30 00:02:53 ovpn-client1[1870]: Outgoing Data Channel: Cipher 'AES-256-CBC' initialized with 256 bit key
Apr 30 00:02:53 ovpn-client1[1870]: Outgoing Data Channel: Using 512 bit message hash 'SHA512' for HMAC authentication
Apr 30 00:02:53 ovpn-client1[1870]: Incoming Data Channel: Cipher 'AES-256-CBC' initialized with 256 bit key
Apr 30 00:02:53 ovpn-client1[1870]: Incoming Data Channel: Using 512 bit message hash 'SHA512' for HMAC authentication
Apr 30 00:02:53 ovpn-client1[1870]: TUN/TAP device tun11 opened
Apr 30 00:02:53 ovpn-client1[1870]: TUN/TAP TX queue length set to 1000
Apr 30 00:02:53 ovpn-client1[1870]: /sbin/ifconfig tun11 10.8.51.6 netmask 255.255.255.0 mtu 1500 broadcast 10.8.51.255
Apr 30 00:02:53 ovpn-client1[1870]: updown.sh tun11 1500 1602 10.8.51.6 255.255.255.0 init
Apr 30 00:02:55 ovpn-client1[1870]: WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
Apr 30 00:02:55 ovpn-client1[1870]: Initialization Sequence Completed
I have even tried to set some explicit rules in iptables:
Code:
admin@Router:/tmp/home/root# iptables -vL
Chain INPUT (policy ACCEPT 132 packets, 18447 bytes)
pkts bytes target prot opt in out source destination
34 1136 ACCEPT igmp -- eth0 any anywhere anywhere
Chain FORWARD (policy ACCEPT 6 packets, 1714 bytes)
pkts bytes target prot opt in out source destination
0 0 ACCEPT all -- any tun11 192.168.51.0/24 anywhere
0 0 ACCEPT all -- tun11 any anywhere 192.168.51.0/24
0 0 ACCEPT all -- eth0 any anywhere base-address.mcast.net/4
892 125K ACCEPT all -- any any anywhere anywhere state RELATED,ESTABLISHED
0 0 other2wan all -- !br0 eth0 anywhere anywhere
0 0 ACCEPT all -- br0 br0 anywhere anywhere
16 784 DROP all -- any any anywhere anywhere state INVALID
180 65179 NSFW all -- any any anywhere anywhere
0 0 ACCEPT all -- any any anywhere anywhere ctstate DNAT
180 65179 OVPN all -- any any anywhere anywhere state NEW
.....
routes on the Router:
Code:
admin@Router:/tmp/home/root# route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
default 192.168.0.1 0.0.0.0 UG 0 0 0 eth0
10.8.51.0 * 255.255.255.0 U 0 0 0 tun11
127.0.0.0 * 255.0.0.0 U 0 0 0 lo
192.168.0.0 * 255.255.255.0 U 0 0 0 eth0
192.168.0.1 * 255.255.255.255 UH 0 0 0 eth0
192.168.51.0 * 255.255.255.0 U 0 0 0 br0
Any guess on what I may be missing?
Thanks in advance.
Last edited: