Networking Forums

Networking Forums > Computer Networking > Linux Networking > DNAT forwarding from two Internet connections / uplinks

Reply
Thread Tools Display Modes

DNAT forwarding from two Internet connections / uplinks

 
 
S P Arif Sahari Wibowo
Guest
Posts: n/a

 
      09-19-2005, 10:55 PM
Hi!

I setup a firewall that connect to two separate Internet
connection. Not the firewall need to do DNAT forwarding (port
forwarding) using iptables to several servers inside LAN. Do you
know how to do that?

I did make the firewall reachable from second Internet
connection using iproute2 setup on different routing table. Bu
how to forward this to other server? The other server will reply
to single firewall address, how the firewall redirect reply from
second Internet connection back to the second Internet
connection?

I tried using SNAT/Masqurading on the connection going out the
firewall, but it doesn't work. First I tried using marking:

iptables -t mangle -A PREROUTING -d <address-of-2nd-internet> -j MARK --set-mark 0xb

iptables -t nat -A POSTROUTING -m mark --mark 0xb -j SNAT --to-source <fw-address-in-LAN>


This doesn't work. Then I tried just SNAT all connection:

iptables -t nat -A POSTROUTING -o eth0 -j SNAT --to-source <fw-address-in-LAN>

But this doesn't work either.

Any idea?

I use linux 2.4.31-grsec with iptables v1.3.1

Thank you!

--
Stephan Paul Arif Sahari Wibowo
_____ _____ _____ _____
/____ /____/ /____/ /____
_____/ / / / _____/ http://www.arifsaha.com/
 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
DNAT forwarding from two Internet connections / uplinks (fwd) S P Arif Sahari Wibowo Linux Networking 2 10-05-2005 08:24 PM
VPN Connections and port forwarding Carolina On-Site Windows Networking 5 06-10-2005 07:39 PM
Multiple uplinks/routes to Internet with one ethernet - MAC problem Felipe Alvarez Linux Networking 1 02-24-2005 04:32 PM
forwarding ssh connections through a gateway bad_knee Linux Networking 0 05-11-2004 06:30 PM
Iptables, DNAT, Forwarding? problem... Mitch Linux Networking 1 04-19-2004 04:23 PM



1 2 3 4 5 6 7 8 9 10 11