stoner
29-05-2010, 00:00
Thanks freshwire I will give that a go over the weekend
# rewrite incoming packets with new destination iptables -t nat -A PREROUTING -d 1.2.3.4 -p tcp -j DNAT --to-destination 5.6.7.8 # rewrite source of outgoing packets iptables -t nat -A POSTROUTING -p tcp -d 5.6.7.8 -j SNAT --to-source 1.2.3.4 # apply the rule to packets we generate iptables -t nat -A OUTPUT -p tcp -d 1.2.3.4 -j DNAT --to-destination 5.6.7.8