0

I am trying to setup an openvpn connection over the SSH tunnel which is having SOCKS proxy, but as soon as I connect to the openvpn server after setting up the SOCKS proxy, the SSH tunnel breaks as OpenVPN redirects all traffic.

Is there any way that I can route my SSH client through my Wifi and use OPENVPN to route traffic through the SSH Tunnel but the SSH Client does not get affected by the connection to the OPENVPN server?

Platform - Windows 8.

3
  • Check out this. Commented Mar 24, 2014 at 8:58
  • @TarekJellali - I am on Windows 8. That guide is for Windows 2000/XP. Commented Mar 24, 2014 at 9:31
  • Those commands are made using cmd, you can try them I think they work. Commented Mar 24, 2014 at 9:59

1 Answer 1

0

Configure OpenVPN to install a /32 route to the SSH server’s network address through your local default gateway, which will override the default route over the VPN tunnel. OpenVPN has a number of options for installing routes directly and running scripts at various stages; find one that adds this route before the connection comes up and the default route is changed.

5
  • Could you please elaborate? Commented Mar 26, 2014 at 16:17
  • On which aspect? Commented Mar 27, 2014 at 15:28
  • Like the steps to follow or the commands to execute? Commented Mar 27, 2014 at 16:14
  • I suggest these steps: read the OpenVPN documentation to find out how to do what I recommended. If anything I wrote is unclear, ask for an explanation. If you have trouble once you’ve done some work on your own, ask a specific question. Commented Mar 28, 2014 at 3:52
  • You can try it out first by simply adding the route before starting OpenVPN, e.g. if your SSH server has IP address 1.2.3.4 and your default gateway is 192.168.1.1, "route add 1.2.3.4/32 192.168.1.1". Later, you may want to automate adding and removing this route via the OpenVPN features I mentioned, determining the SSH server address from its hostname. Commented Mar 30, 2014 at 1:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .