вторник, 28 апреля 2015 г.

Iptables change packet destination address


So you've faced this problem - you can't do anything to application and you know which host this application trying to connect. For example, your application connects to remote host 10.10.20.103, but you need it to connect to 8.8.4.4. So here's simple solution, as simple as this:
iptables -t nat -I OUTPUT --dest 10.10.20.103 -j DNAT --to-dest 8.8.4.4

Комментариев нет:

Отправить комментарий