iptables change destination IP without DNAT

Posted by Mad_Ady on Server Fault See other posts from Server Fault or by Mad_Ady
Published on 2010-03-19T09:39:53Z Indexed on 2010/03/19 9:41 UTC
Read the original article Hit count: 158

Filed under:

Hello, I'm trying to workaround a broken application which insists on connecting to the private address (and thus unreachable) of a server, instead of connecting to the public address (even if the relevant port is open). Changing the application is not an option.

I'm trying to add iptables rules on the client(s) to change the destination ip for the packets going to 192.168.251.3 to go to 1.2.3.4 instead. DNAT isn't working since 1.2.3.4 is not an IP on any of my client interfaces.

Can anyone point me to the relevant documentation that allows me to use MANGLE to change destination IPs?

© Server Fault or respective owner

Related posts about iptables