Re: how to Port Forward

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Am Do, den 09.06.2005 schrieb Alexander Dalloz um 16:20:

> > If I am wrong then can someone please show me how to do it with NAT.
> 
> > Shaz 
> 
> It is no problem.
> 
> iptables -A PREROUTING -i <input device> -p tcp --dport 22 -j DNAT --to
> <target IP>:22022
> 
> Alexander

Sorry, forgot about the SNAT rule:

iptables  -A POSTROUTING -t nat -s <target IP> -p tcp --dport 22022 -j
SNAT --to <input IP>:22

You see, DNAT and SNAT have to be inverse rules.

Alexander


-- 
Alexander Dalloz | Enger, Germany | GPG http://pgp.mit.edu 0xB366A773
legal statement: http://www.uni-x.org/legal.html
Fedora Core 2 GNU/Linux on Athlon with kernel 2.6.11-1.27_FC2smp 
Serendipity 16:27:21 up 16 days, 15:05, load average: 0.19, 0.19, 0.09 

Attachment: signature.asc
Description: Dies ist ein digital signierter Nachrichtenteil


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux