mirror of
https://github.com/nmap/nmap.git
synced 2025-12-15 20:29:03 +00:00
Account for VLAN header in pcap packets if needed.
This commit is contained in:
2
tcpip.cc
2
tcpip.cc
@@ -1610,7 +1610,7 @@ int setTargetMACIfAvailable(Target *target, struct link_header *linkhdr,
|
||||
if (!linkhdr || !target || !src)
|
||||
return 1;
|
||||
|
||||
if (linkhdr->datalinktype != DLT_EN10MB || linkhdr->headerlen != 14)
|
||||
if (linkhdr->datalinktype != DLT_EN10MB || linkhdr->headerlen < 14)
|
||||
return 2;
|
||||
|
||||
if (!overwrite && target->MACAddress())
|
||||
|
||||
Reference in New Issue
Block a user