Routing question OpenVPN Connect 1.1.1

Official client software for OpenVPN Access Server and OpenVPN Cloud.
Post Reply
untos
OpenVpn Newbie
Posts: 5
Joined: Fri Feb 09, 2018 6:54 pm

Routing question OpenVPN Connect 1.1.1

Post by untos » Thu Nov 15, 2018 5:43 pm

I am testing this older ios8 iPad on the home network and have a routing question.

My OpenVPN server is 192.168.1.1
My iPad is 192.168.1.55

server.conf:
server 192.168.112.0 255.255.255.192
push "redirect-gateway def1"
push "dhcp-option DNS 192.168.1.1"

My iPad connects and has VPN assigned address 192.168.112.2. I can connect to the internet am routed through this IP according to iptables. But when I connect directly to 192.168.1.1's web server the apache log says my iPad is 192.168.1.55.

How can I access the openvpn server and all systems on the 192.168 network over the encrypted VPN using 192.168.112.2?

TinCanTech
OpenVPN Protagonist
Posts: 11137
Joined: Fri Jun 03, 2016 1:17 pm

Re: Routing question OpenVPN Connect 1.1.1

Post by TinCanTech » Thu Nov 15, 2018 10:14 pm

untos wrote:
Thu Nov 15, 2018 5:43 pm
when I connect directly to 192.168.1.1's web server the apache log says my iPad is 192.168.1.55.
Correct .. 192.168.1.1 is your default gateway and cannot be redirected over the VPN.

But you can access 192.168.1.1 over the VPN if your client is located on a different network, like a school.

untos
OpenVpn Newbie
Posts: 5
Joined: Fri Feb 09, 2018 6:54 pm

Re: Routing question OpenVPN Connect 1.1.1

Post by untos » Fri Nov 16, 2018 2:31 am

If I wanted ALL traffic with the server (vnc, smb, web, except dhcp and the vpn itself..) encrypted through the VPN, whether my iPad was on the 192.168 home network or away, what is the right (and easiest) way to set that up?

TinCanTech
OpenVPN Protagonist
Posts: 11137
Joined: Fri Jun 03, 2016 1:17 pm

Re: Routing question OpenVPN Connect 1.1.1

Post by TinCanTech » Fri Nov 16, 2018 2:20 pm

You cannot do this when your client is on the same subnet as your server.

Post Reply