From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Ilo" Subject: Portfowarding not working while SNATing, Date: Tue, 15 Jul 2003 08:33:00 +0200 Sender: netfilter-admin@lists.netfilter.org Message-ID: <006501c34a9a$efc8d040$4c00000a@sneak> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0062_01C34AAB.B34A7450" Return-path: Errors-To: netfilter-admin@lists.netfilter.org List-Help: List-Post: List-Subscribe: , List-Id: List-Unsubscribe: , List-Archive: To: netfilter@lists.netfilter.org This is a multi-part message in MIME format. ------=_NextPart_000_0062_01C34AAB.B34A7450 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable If have the following set for some port forwarding that I need done, = which works well... /sbin/iptables -t nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 = --dport 80 -j DNAT --to 10.0.0.2:80 /sbin/iptables -t nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 = --dport 389 -j DNAT --to 10.0.0.2:389 then once I set the following for SNAT so my local machines can get = internet access my port forwarding=20 stops working. /sbin/iptables -t nat -A POSTROUTING -o eth0 -j SNAT --to 196.11.11.11 Is there something im not doing right? can someone point me in the right = direction. tx. ------=_NextPart_000_0062_01C34AAB.B34A7450 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
If have the following set for some port = forwarding=20 that I need done, which works well...
 
/sbin/iptables -t nat -A PREROUTING = -p tcp -i=20 eth0 -d 196.11.11.11 --dport 80 -j DNAT --to = 10.0.0.2:80
/sbin/iptables -t=20 nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 --dport 389 -j DNAT = --to=20 10.0.0.2:389

then once I set the following for SNAT = so my local=20 machines can get internet access my port forwarding
stops working.
 
/sbin/iptables -t nat -A = POSTROUTING -o eth0 -j=20 SNAT --to 196.11.11.11
 
 
Is there something im not doing right? can someone point me in the = right=20 direction.
 
tx.
------=_NextPart_000_0062_01C34AAB.B34A7450-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: "George Vieira" Subject: RE: Portfowarding not working while SNATing, Date: Tue, 15 Jul 2003 16:45:15 +1000 Sender: netfilter-admin@lists.netfilter.org Message-ID: <09B04A55822EFF4DA48D2E0BB2941D4A15BF19@wardrive.citadelcomputer.com.au> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="----_=_NextPart_001_01C34A9C.A5CDE596" Return-path: content-class: urn:content-classes:message Errors-To: netfilter-admin@lists.netfilter.org List-Help: List-Post: List-Subscribe: , List-Id: List-Unsubscribe: , List-Archive: To: Ilo , netfilter@lists.netfilter.org This is a multi-part message in MIME format. ------_=_NextPart_001_01C34A9C.A5CDE596 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable How about telling us what the problem is and what you've done to = eliminate/test it.. ie. tcpdumping, -j LOG, etc.. =20 I would've used -j MASQUERADE instead of SNAT personally...... =20 Thanks, =20 ____________________________________________ George Vieira Citadel Computer Systems Pty Ltd Systems Manager georgev AT = citadelcomputer DOT com DOT au=20 Citadel Computer Systems Pty Ltd Phone : +61 2 9955 2644 HelpDesk: +61 2 9955 2698 = http://www.citadelcomputer.com.au =20 =20 -----Original Message----- From: Ilo [mailto:sneak@gmsg.co.za] Sent: Tuesday, July 15, 2003 4:33 PM To: netfilter@lists.netfilter.org Subject: Portfowarding not working while SNATing, If have the following set for some port forwarding that I need done, = which works well... =20 /sbin/iptables -t nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 = --dport 80 -j DNAT --to 10.0.0.2:80 /sbin/iptables -t nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 = --dport 389 -j DNAT --to 10.0.0.2:389 then once I set the following for SNAT so my local machines can get = internet access my port forwarding=20 stops working. =20 /sbin/iptables -t nat -A POSTROUTING -o eth0 -j SNAT --to 196.11.11.11 =20 =20 Is there something im not doing right? can someone point me in the right = direction. =20 tx. ------_=_NextPart_001_01C34A9C.A5CDE596 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
How=20 about telling us what the problem is and what you've done to = eliminate/test it..=20 ie. tcpdumping, -j LOG, etc..
 
I=20 would've used -j MASQUERADE instead of SNAT = personally......
 

Thanks,

 
____________________________________________George=20 Vieira
Citadel=20 Computer Systems Pty Ltd Systems=20 Manager georgev AT=20 citadelcomputer DOT com DOT au
Citadel Computer Systems Pty Ltd
Phone : +61 2 9955=20 2644 HelpDesk: +61 2 9955=20 2698 http://www.citadelcomputer.co= m.au
 
 
-----Original Message-----
From: Ilo=20 [mailto:sneak@gmsg.co.za]
Sent: Tuesday, July 15, 2003 4:33=20 PM
To: netfilter@lists.netfilter.org
Subject: = Portfowarding=20 not working while SNATing,

If have the following set for some port = forwarding=20 that I need done, which works well...
 
/sbin/iptables -t nat -A PREROUTING = -p tcp -i=20 eth0 -d 196.11.11.11 --dport 80 -j DNAT --to = 10.0.0.2:80
/sbin/iptables -t=20 nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 --dport 389 -j DNAT = --to=20 10.0.0.2:389

then once I set the following for SNAT = so my local=20 machines can get internet access my port forwarding
stops working.
 
/sbin/iptables -t nat -A = POSTROUTING -o eth0 -j=20 SNAT --to 196.11.11.11
 
 
Is there something im not doing right? can someone point me in the = right=20 direction.
 
tx.
------_=_NextPart_001_01C34A9C.A5CDE596-- From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Ilo Lorusso" Subject: Portfowarding not working while SNATing, Date: Tue, 15 Jul 2003 08:30:16 +0200 Sender: netfilter-admin@lists.netfilter.org Message-ID: <004e01c34a9a$8f2b3b60$4c00000a@sneak> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_004B_01C34AAB.51C0D1C0" Return-path: Errors-To: netfilter-admin@lists.netfilter.org List-Help: List-Post: List-Subscribe: , List-Id: List-Unsubscribe: , List-Archive: To: netfilter@lists.netfilter.org This is a multi-part message in MIME format. ------=_NextPart_000_004B_01C34AAB.51C0D1C0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable If have the following set for some port forwarding that I need done, = which works well... /sbin/iptables -t nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 = --dport 80 -j DNAT --to 10.0.0.2:80 /sbin/iptables -t nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 = --dport 389 -j DNAT --to 10.0.0.2:389 then once I set the following for SNAT so my local machines can get = internet access my port forwarding=20 stops working. /sbin/iptables -t nat -A POSTROUTING -o eth0 -j SNAT --to 196.11.11.11 Is there something im not doing right? can someone point me in the right = direction. tx. ------=_NextPart_000_004B_01C34AAB.51C0D1C0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
If have the following set for some port = forwarding=20 that I need done, which works well...
 
/sbin/iptables -t nat -A PREROUTING = -p tcp -i=20 eth0 -d 196.11.11.11 --dport 80 -j DNAT --to = 10.0.0.2:80
/sbin/iptables -t=20 nat -A PREROUTING -p tcp -i eth0 -d 196.11.11.11 --dport 389 -j DNAT = --to=20 10.0.0.2:389

then once I set the following for SNAT = so my local=20 machines can get internet access my port forwarding
stops working.
 
/sbin/iptables -t nat -A = POSTROUTING -o eth0 -j=20 SNAT --to 196.11.11.11
 
 
Is there something im not doing right? can someone point me in the = right=20 direction.
 
tx.
------=_NextPart_000_004B_01C34AAB.51C0D1C0--