Redirecionar/NAT de pacotes

Encaminhar pacotes vindos para o IP do firewall na porta 5900 para um IP interno da rede

iptables -t nat -A PREROUTING -d 200.157.231.195 -p tcp --dport 5900 -j DNAT --to-destination 192.168.0.253

iptables -t nat -A POSTROUTING -s 192.168.0.253 -p tcp --dport 5900 -j SNAT --to-source 200.157.231.195

iptables -A FORWARD -d 192.168.0.253 -p tcp --dport 5900 -m state --state NEW,ESTABLISHED -j ACCEPT
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s