using iptables to route thru specific interface?

From: Tobias Skytte (tobias_at_itservices.co.mz)
Date: 12/22/03


Date: 22 Dec 2003 07:33:43 -0800

Hi,

I have recently discovered that my ISP, who provides me with a vpn
tunnel for reception, is filtering out smtp, dns, telnet, ping and
other packets. Thus I can not telnet into my machine from the outside
even though I also have a DSL line to that server (that I use for
sending out thru).
This is set up on RH 7.1, using PPTP for the tunnel.
So what happens in a ping for example is this:
I ping from outside and it enters on eth0 which is the DSL connection.
The server sends a pong-reply but the reply is sent to the default
route which points to the VPN server thru ppp0.
The reply gets dropped in the VPN server.

So what I need is something that makes the reply packet bypass the
normal default route and go straight to the sender.
Someone told me I should be able to do this with iptables, but as I am
new to it I am not sure how.
Should I use DNAT? or mark the packages or what? I have read up on it
but am still confused.
Can this be done with ipchains?
I am sure someone has done the same before, maybe someone knows of a
good description on exactly what to do?

Best regards,
Tobias Skytte



Relevant Pages

  • Re: problem with network in vpn
    ... juste one anather question can i setup one DC as VPN server? ... routing issues on vpn ... 1) if you have two NICs in the VPN server, ... i can ping the vpn server the ip 192.168.0.66 but if i like to ping the ...
    (microsoft.public.windows.server.general)
  • RE: connect VPN from internet fails
    ... Total Mappings, Inbound packets translated,Inbound packets ... Does this mean that the VPN connection were rejected? ... > I have a problem access VPN server from internet but I can access the VPN ... > server from the same 4-ports router. ...
    (microsoft.public.windows.server.networking)
  • Re: VPN errors After SBS2003 SP1 install.
    ... ONE connection. ... > A connection between the VPN server and the VPN client 222.152.16.132 has ... > routers between your VPN server and the Internet allow GRE packets. ...
    (microsoft.public.windows.server.sbs)
  • Re: Another "Cant Browse Network over VPN" question...
    ... chars with spaces] ... I can ping the ... > and the local IP given by the VPN server. ...
    (microsoft.public.windows.server.sbs)
  • Re: problem with network in vpn
    ... It is not recommended to setup VPN on a DC. ... juste one anather question can i setup one DC as VPN server? ... i can ping the vpn server the ip 192.168.0.66 but if i like to ping the ...
    (microsoft.public.windows.server.general)

Loading