redirect port 26 to port 25 in linux

iptables -t nat -A PREROUTING -p tcp –dport 26 -j REDIRECT –to-ports 25

so that mean if the server using port 25 for SMTP , and your ISP block port 25, then run this command and use port 26 then automaticlly will change to port 25 once reach the server

Thank you.

Leave a Reply