zmap: echo_reply ignored when coming in on different interface
Describe the bug When starting a ZMap scan with icmp_echoscan over a certain interface with given gateway-mac and source-ip, it can happen, that the echo_reply comes in on an other interface than the echo_request was sent. Then ZMap does not recognize this answer and it appears not to be reachable. Trying to reach the same ip addresses with ping is possible, even if the echo_reply comes in over the “wrong” interface.
CLI Arguments ZMap only displays “193.169.204.70” as reachable, “177.125.150.95” seems to be lost. Ping can ping both.
sudo zmap -i tap5 -r 100 -M icmp_echoscan --source-ip=184.164.235.1 -I /tmp/hitlisttest_v4 --gateway-mac=c2:39:de:b9:c2:ec
ping4 -I 184.164.235.1 193.169.204.70
ping4 -I 184.164.235.1 177.125.150.95
cat /tmp/hitlisttest_v4
193.169.204.70
177.125.150.95
sudo tcpdump -e -i any host 177.125.150.95 or host 193.169.204.70
TCPDUMP while PING
11:41:34.966440 Out 5e:33:ae:36:5e:37 (oui Unknown) ethertype IPv4 (0x0800), length 100: 184.164.235.1 > 193.169.204.70: ICMP echo request, id 1251, seq 1, length 64
11:41:35.000138 In c2:39:de:b9:c2:ec (oui Unknown) ethertype IPv4 (0x0800), length 100: 193.169.204.70 > 184.164.235.1: ICMP echo reply, id 1251, seq 1, length 64
11:41:41.903974 Out b6:d0:72:29:c7:59 (oui Unknown) ethertype IPv4 (0x0800), length 100: 184.164.235.1 > 177.125.150.95: ICMP echo request, id 1269, seq 1, length 64
11:41:42.216155 In f6:ad:dc:cd:60:7f (oui Unknown) ethertype IPv4 (0x0800), length 100: 177.125.150.95 > 184.164.235.1: ICMP echo reply, id 1269, seq 1, length 64
TCPDUMP while ZMap
11:16:04.721532 In c2:39:de:b9:c2:ec (oui Unknown) ethertype IPv4 (0x0800), length 56: 193.169.204.70 > 184.164.235.1: ICMP echo reply, id 35397, seq 40100, length 20
11:17:03.358541 In f6:ad:dc:cd:60:7f (oui Unknown) ethertype IPv4 (0x0800), length 56: 177.125.150.95 > 184.164.235.1: ICMP echo reply, id 21148, seq 27869, length 20
Example Target IP
193.169.204.70 177.125.150.95
Expected behavior No hit in ZMap for an IP address, if the reply comes in over another interface than the request was sent from.
Environment:
- OS: Debian GNU/Linux 10 (buster)
- Version: zmap Development Build. Commit dd31295 - Sat Aug 24 20:58:25 2019 +0200
Additional context Is it possible to add an parameter that tells ZMap to listen to all interfaces, if you consider this as a feature, not a bug?
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 16 (7 by maintainers)
Ah OK, that’s unfortunate. It might not be possible to do this looking more at how these generic interfaces are used. I’ll read some more, but it doesn’t seem optimistic so far.