1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-31 20:09:02 +00:00

Merged r27296 from nmap-npingchages: Add some missing code to support ICMP domain name requests

This commit is contained in:
luis
2013-03-29 13:31:04 +00:00
parent ac64c953ab
commit 2fa6124a79

View File

@@ -329,6 +329,8 @@ bool ICMPv4Header::validateType(u8 val){
case ICMP_MASK:
case ICMP_MASKREPLY:
case ICMP_TRACEROUTE:
case ICMP_DOMAINNAME:
case ICMP_DOMAINNAMEREPLY:
return true;
break;
@@ -1060,6 +1062,11 @@ int ICMPv4Header::getICMPHeaderLengthFromType( u8 type ) const {
case ICMP_TRACEROUTE:
return 20;
break;
case ICMP_DOMAINNAME:
case ICMP_DOMAINNAMEREPLY:
return 8;
break;
/* Packets with non RFC-Compliant types will be represented as
an 8-byte ICMP header, just like the types that don't include