Redirect / Rewrite destination IP address using iptables

Posted by - 27th June 2012

Just a quick one on how to alter the destination of an outbound connection IP using iptables. I imagine a few tweaks would allow this to work in the sense of redirecting through a proxy etc too. iptables -t nat -I OUTPUT –dest -p tcp –dport 80 -j DNAT –to-dest This one will