From eba17126a11e250d32d1684a058b81198a4f9770 Mon Sep 17 00:00:00 2001 From: dmiller Date: Sun, 7 Jun 2015 14:38:05 +0000 Subject: [PATCH] Fix assertion error #154 --- scan_engine_raw.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scan_engine_raw.cc b/scan_engine_raw.cc index 6d4b59aac..40e0a2ee2 100644 --- a/scan_engine_raw.cc +++ b/scan_engine_raw.cc @@ -652,7 +652,8 @@ int get_ping_pcap_result(UltraScanInfo *USI, struct timeval *stime) { sockaddr_storage_cmp(&target_src, &hdr.dst) != 0 || sockaddr_storage_cmp(&target_src, &encaps_hdr.src) != 0 || sockaddr_storage_cmp(&target_dst, &encaps_hdr.dst) != 0 || - ntohs(ping->id) != probe->icmpid()) + ((probe->protocol() == IPPROTO_ICMP || probe->protocol() == IPPROTO_ICMPV6) && + ntohs(ping->id) != probe->icmpid())) continue; if ((encaps_hdr.proto == IPPROTO_ICMP || encaps_hdr.proto == IPPROTO_ICMPV6)