Hello,
I would like to force the traffic from one computer (connected to the network by openvpn to use the Openvpn server to go on some web sites.
Here is an example :
My work ISP gives me an IP address (for example 1.2.3.4)
At home I have another fixed ip address (5.6.7.8).
I want to use a service from my work isp, but the service is firewalled. Only the adress 1.2.3.4 will be able to use the service.
So I have added the lines
push "route 212.71.0.11 255.255.255.255"
push "route 212.71.16.196 255.255.255.255"
by thinking that it would be fine, but it doesn't work.
I have also used the command on my computer and it doesn't work.
route add 212.71.0.11 mask 255.255.255.255 192.168.123.254
route add 212.71.16.196 mask 255.255.255.255 192.168.123.254
Can you please tell me what I am missing?
If I use PPTP instead of openvpn, there is no problem with the command so I suppose I have to do something else for it to work with openvpn.
Thank you
Marc
Force IP adresses to go throught the Server
Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech
-
- OpenVpn Newbie
- Posts: 11
- Joined: Thu Oct 13, 2011 5:11 am
- Mimiko
- Forum Team
- Posts: 1564
- Joined: Wed Sep 22, 2010 3:18 am
Re: Force IP adresses to go throught the Server
This is not an OpenVPN matter.
You have to configure iptables on OpenVPN server as well to route traffic for that ip from tunell to GW.
You have to configure iptables on OpenVPN server as well to route traffic for that ip from tunell to GW.
-
- OpenVpn Newbie
- Posts: 11
- Joined: Thu Oct 13, 2011 5:11 am
Re: Force IP adresses to go throught the Server
Hello,
I don't understand what you mean
What is iptable? I was thinking that it was a firewall on Linux?
I am on Windows 2008 Server R2
Is it a parameter in the config of openvpn on the server?
is it something else
Thank you
Marc
I don't understand what you mean

What is iptable? I was thinking that it was a firewall on Linux?
I am on Windows 2008 Server R2
Is it a parameter in the config of openvpn on the server?
is it something else
Thank you
Marc
- Mimiko
- Forum Team
- Posts: 1564
- Joined: Wed Sep 22, 2010 3:18 am
Re: Force IP adresses to go throught the Server
Oh, sorry, forget you are on windows.
You have to use on server some network share solution: 3rd software or internal internet sharing. So any access from tunnel to internet is allowed and NATed.
On clients you are doing write, adding routes for the specific sites to go thru tunnel.
You have to use on server some network share solution: 3rd software or internal internet sharing. So any access from tunnel to internet is allowed and NATed.
On clients you are doing write, adding routes for the specific sites to go thru tunnel.
-
- OpenVpn Newbie
- Posts: 11
- Joined: Thu Oct 13, 2011 5:11 am
Re: Force IP adresses to go throught the Server
Hello,
Thank you I have seen the parameter : on the properties of the Local connection (192.168.123.25) I have enabled the sharing of the port I need (5060 for voip and now all is fine).
Marc
Thank you I have seen the parameter : on the properties of the Local connection (192.168.123.25) I have enabled the sharing of the port I need (5060 for voip and now all is fine).
Marc