Connect to vpn without forcing computer to use that connection

This forum is for general conversation and user-user networking.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Post Reply
User avatar
Nemesis
OpenVpn Newbie
Posts: 15
Joined: Sun Apr 08, 2018 7:30 pm

Connect to vpn without forcing computer to use that connection

Post by Nemesis » Sun Jan 05, 2020 1:54 pm

Hi all!
I've been trying to go around a server that refuses to work on vpn, so I have a "weird" question.

I'm on a windows 10 machine, and have installed openvpn and everything is working.
BUT! I want to have the connection to my vpn running, but I want to have my windows 10 machine to "skip" the vpn, and instead running on my normal IP.
(Metric doesn't work)

Background:
I'm running a virtualbox with Linux, I have shared the tap9 network card with the local Host adapter to virtualbox, and that way forced Linux to only access the network thru the tap9 (the vpn), got the idea from here;
https://serverfault.com/questions/12712 ... on-windows

This way, I can fool the server in the Linux computer to think it's a normal internet connection, and not vpn.
This is also the reason why I don't just add openvpn to Linux and run it from there, the vpn works, but the server refuses.

So by doing this solution, everything seems to be working fine, but, as I specified earlier, this causes my windows 10 machine to also use the vpn, and that's what I need help with to solve..

Code: Select all

 Router IP: 192.168.1.1
 Virtualbox host only IP:192.168.137.1
 Linux IP: 192.168.137.2  
 Windows 10 IP: 192.168.1.21
My current openvpn config:
Configuration openvpn

client
dev tun
remote-cert-tls server
cipher aes-256-cbc
pull
nobind
reneg-sec 0
resolv-retry infinite
verb 3
persist-key
persist-tun
remote-random
remote pool-1.prd.se.sthlm.ovpn.com 1194
remote pool-1.prd.se.sthlm.ovpn.com 1195
remote pool-2.prd.se.sthlm.ovpn.com 1194
remote pool-2.prd.se.sthlm.ovpn.com 1195
proto udp
mute-replay-warnings
replay-window 256
auth-user-pass
ncp-ciphers AES-256-GCM:AES-256-CBC:AES-128-GCM
key-direction 1
block-outside-dns
sndbuf 524288
rcvbuf 524288


So, is it possible somehow to still have the openvpn connection active, and still use the routers IP on the main computer?

Post Reply