1

I'm trying to forward all icmp requests from source ip 5.10.13.13 to new destination ip 5.10.11.11. IP of current local machine, where i'm applying iptables rule is 5.10.10.10. I apply this rule:

sudo iptables -t nat -A PREROUTING -p icmp –icmp-type 8 -s 5.10.13.13 -j DNAT –to-destination 5.10.11.11

The issue is in replying to this icmp request from 5.10.10.10. In other words, in my tcpdump

tcpdump -ni eth0 -p

I saw this records:

IP 5.10.10.10 > 5.10.11.11 ICMP echo request
IP 5.10.10.10 > 5.10.13.13 ICMP echo reply

Question: Why forwarding of icmp request works normally, but replying to this icmp request working too

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.