Sunday, July 4, 2021

IPTables question regarding POSTROUTING / PREROUTING.

Hopefully someone can help.

I was trying to add a rule in the iptables firewall, so that a certain private ip, let's say 192.168.0.15 to be allow to acces the 6991, 8991 and 80 ports, and the public ip 86.10.1.101 considering the gateway is 86.10.1.10.

Is this command correct?

IPTABLES -t nat -A POSTROUTING -p tcp -s 192.168.0.15 -d 86.10.1.101 -m multiport --dports 6991, 8991, 80 -j SNAT --to-source 86.10.1.10



No comments:

Post a Comment