Ok, so Many ISPs are now blocking port 25 on outgoing connections, so I set up an smtp server on port 1025. Now this works great and configured clients send mail properly. But for most of the code already on the server, the smtp server should be on 25, now rather than reconfigure all the code to use the new port I was thinking of establishing a tunnel or something to force all from localhost to 25 to go to localhost on 1025.
I tried this and it did not work
iptables -t nat -A PREROUTING -p tcp -i lo --dport 25 -j DNAT --to 127.0.0.1:1025
what can I do to accomplish this?
thank you