You are not logged in.
Is it possible to route only certain traffic through VPN and other through default gw route?
I have tried to google it, i didn't find anything usefull.
Thank you
ArchLinux x86_64 | scripts | .configs | cyber space | Last.FM | deviantART
Offline
If the traffic is all to a certain network you could add a routing entry specifying where to route it through:
route add -net 192.57.66.0 netmask 255.255.255.0 gw 1.2.3.4
Check 'man route' for more examples.
Offline
If the traffic is all to a certain network you could add a routing entry specifying where to route it through:
route add -net 192.57.66.0 netmask 255.255.255.0 gw 1.2.3.4Check 'man route' for more examples.
Yes, that will route all traffic through that gw. But, what I want is to redirect traffic from certain ports through other gw.
ArchLinux x86_64 | scripts | .configs | cyber space | Last.FM | deviantART
Offline
Replace 'eth1' with 'ppp0' or 'tun0' or whatever your VPN interface is:
http://bbs.archlinux.org/viewtopic.php? … 63#p497763
Then for the ports you want to send via the VPN, add a rule like this:
iptables -t mangle -A OUTPUT -p tcp --dport XX -m state --state NEW -j MARK --set-mark 102
Last edited by fukawi2 (2009-09-21 23:09:11)
Are you familiar with our Forum Rules, and How To Ask Questions The Smart Way?
BlueHackers // fscanary // resticctl
Offline