1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-06 04:31:29 +00:00

Use FQDN_LEN instead of MAXHOSTNAMELEN for DNS name buffers

This closes #140 (issue #140), namely "Use correct lengths 
for FQDN, not MAXHOSTNAMELEN"
This commit is contained in:
vincent
2016-07-26 14:06:22 +00:00
parent fcb94e2018
commit 32efc8b28c
9 changed files with 28 additions and 17 deletions

3
nmap.h
View File

@@ -323,6 +323,9 @@
#define MAXHOSTNAMELEN 64
#endif
/* Length of longest DNS name */
#define FQDN_LEN 254
/* Max payload: Worst case is IPv4 with 40bytes of options and TCP with 20
* bytes of options. */
#define MAX_PAYLOAD_ALLOWED 65535-60-40