1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-07 21:21:31 +00:00
Commit Graph

494 Commits

Author SHA1 Message Date
dmiller
24f6cec25a Move scan lists structs and functions to scan_lists files. 2017-04-19 04:14:43 +00:00
dmiller
71f86bf2ec Remove some unused function prototypes 2017-04-19 02:17:20 +00:00
fyodor
4bd67aa2fb Update the Nmap license/header text to reflect latest updates to docs/legal-notices.xml 2016-12-14 00:12:23 +00:00
dmiller
3f1ad0742e New option --defeat-icmp-ratelimit. Closes #353, Fixes #216 2016-12-09 04:19:45 +00:00
dmiller
b18d6fe5f7 Add --resume from XML output. Closes #316. See #243 2016-12-06 02:55:55 +00:00
dmiller
062d272d0f Make --open imply --defeat-rst-ratelimit 2016-11-28 17:11:01 +00:00
dmiller
82ea8a80d3 Fixed -iR scanning too many targets
Fixed a discrepancy between the number of targets selected with -iR and
the number of hosts scanned. Because "up" hosts did not count towards
the number of hosts in a hostgroup, Nmap would run an extra Ping scan
phase on that number of new targets before scanning. Those extra targets
in the last hostgroup would result in output like "Nmap done: 1056 IP
addresses" when the user specified -iR 1000.

https://security.stackexchange.com/questions/138150/scans-more-ips-than-asked
2016-09-29 14:56:47 +00:00
dmiller
91032d05dd Grab a more-complete Npcap version string 2016-09-21 05:19:25 +00:00
jah
c6c5939220 Comment-out the port spec test suite. 2016-09-19 09:25:18 +00:00
david
59cc2fe72a Avoid eating 'T' 'U' 'S' 'P' not followed by ':' in getpts.
On reading 'T', 'U', 'S', or 'P', getpts_aux would unconditionally
consume the character before checking to see whether it was followed by
a ':'. You could insert 'T', 'U', 'S', or 'P' in several places and it
would just be ignored, which is different treatment than other letters
got.

Behavior before:
	nmap -p 9
	# scans port 9

	nmap -p discard
	# scans port 9

	nmap -p Tdiscard
	# scans port 9

	nmap -p T:Tdiscard
	# scans port 9

	nmap -p Tdi*ard
	# scans port 9

	nmap -p Xdiscard
	# Error #485: Your port specifications are illegal.  Example of proper form: "-100,200-1024,T:3000-4000,U:60000-"

Behavior after:
	nmap -p 9
	# scans port 9

	nmap -p discard
	# scans port 9

	nmap -p Tdiscard
	# Error #485: Your port specifications are illegal.  Example of proper form: "-100,200-1024,T:3000-4000,U:60000-"

	nmap -p T:Tdiscard
	# Error #485: Your port specifications are illegal.  Example of proper form: "-100,200-1024,T:3000-4000,U:60000-"

	nmap -p Tdi*ard
	# Error #485: Your port specifications are illegal.  Example of proper form: "-100,200-1024,T:3000-4000,U:60000-"

	nmap -p Xdiscard
	# Error #485: Your port specifications are illegal.  Example of proper form: "-100,200-1024,T:3000-4000,U:60000-"
2016-09-18 20:42:56 +00:00
david
3a62c2dbc9 Fix typo in commented p-switch-test line.
error: ‘struct scan_lists’ has no member named ‘stcp_count’
2016-09-18 20:42:52 +00:00
dmiller
e6f65878b9 Initialize Npcap before applying delayed options so isr00t is set correctly 2016-09-01 03:34:24 +00:00
dmiller
5cfc7e8564 Delay processing of -A until all --un/privileged options have been seen 2016-09-01 03:34:23 +00:00
abhishek
cd0b373130 Add --script-timeout option to limit the script's runtime. Closes #330 and Fixes #234. 2016-08-20 18:57:47 +00:00
abhishek
9d288db7fd Add support for decoys in IPv6 closes #433 and fixes #98 2016-08-17 06:09:09 +00:00
tudor
c2b139e9bf Avoiding target_needs_new_hostgroup calls seems to make ARP Ping crash so I reverted it. Also checked if Target.size() is not empty before doing Target[0] in nmap_main. 2016-08-14 12:50:42 +00:00
tudor
3ba4a87c75 o.ping_group_sz can be increased above 4096 with a higher --min-hostgroup value, calls to target_needs_new_hostgroup limited as much as possible 2016-08-09 06:12:17 +00:00
vincent
32efc8b28c Use FQDN_LEN instead of MAXHOSTNAMELEN for DNS name buffers
This closes #140 (issue #140), namely "Use correct lengths 
for FQDN, not MAXHOSTNAMELEN"
2016-07-26 14:06:22 +00:00
dmiller
1d3aa1ee57 Clarify and avoid compiler warning
clang 3.4.1 on FreeBSD gave this warning:

    nmap.cc:3064:48: warning: use of logical '||' with constant operand
          [-Wconstant-logical-operand]
        return file_is_readable(filename_returned) || 1;
    nmap.cc:3064:48: note: use '|' for a bitwise operation

Changed to match the intent: return 1 if file_is_readable returns 0, otherwise
return that non-0 value.
2016-06-21 23:40:36 +00:00
dmiller
40dc52cfaa Ensure (Wi)Npcap dll is loaded before trying to call version function 2016-06-14 14:16:47 +00:00
dmiller
fbddc99f6d Grab pcap library name as well as version 2016-04-28 02:40:16 +00:00
dmiller
6e33d6ac3c Bump date in copyright headers 2016-04-04 15:38:44 +00:00
dmiller
3c994776f7 Make use of -4 with -6 illegal. 2016-03-14 23:54:51 +00:00
dmiller
747112554b Print getopt warnings after options summary when exiting. Fixes #269, Closes #272 2016-01-26 04:52:29 +00:00
dmiller
c8d64e9009 Print a helpful message when --resume is used with other options. Closes #84 2016-01-07 05:45:48 +00:00
dmiller
b9367a6f53 Add -v0 to mean no output to stdout. Closes #265. Fixes #236. 2016-01-06 16:26:07 +00:00
dmiller
4e73ed7efd Allow -4 option signifying IPv4 mode 2015-12-21 04:10:38 +00:00
dmiller
f4619edece Update http urls for nmap.org to https 2015-11-05 20:41:05 +00:00
dmiller
e39d3e4101 Fix deprecation warning on -iL by not coercing it to -i, the actual deprecated option 2015-10-20 17:48:56 +00:00
dmiller
a02a29c28f Warn about deprecated option names with -v 2015-09-09 02:50:51 +00:00
dmiller
66022b9672 Another filename check for bad options like -oG- (creates file G-) 2015-09-09 02:50:50 +00:00
dmiller
bc7d670911 Correct spelling of 'deprecated' vs 'depreciated' 2015-09-09 02:50:49 +00:00
dmiller
0effedaf9e Add filename checks to deprecated output file options 2015-09-09 02:50:47 +00:00
dmiller
ea4096c681 Strip or relocate more includes from nmap.h 2015-07-01 21:25:39 +00:00
dmiller
d02f2e41bd include signal.h, needed on Solaris 2015-07-01 04:35:25 +00:00
dmiller
5e47450bdc Use forward-declaration of class FingerPrintResults in Target.h 2015-06-30 04:04:51 +00:00
dmiller
80f8eb6bce Use forward-declaration of class Target instead of including Target.h in *.h 2015-06-30 04:04:48 +00:00
dmiller
638a123ba6 Move osscan structs from global_structures to osscan2.h 2015-06-23 15:53:05 +00:00
fyodor
c697f458e0 Use our https URL in more places instead of the non-SSL one 2015-06-20 02:56:02 +00:00
dmiller
68409b2226 Update copyright date to 2015 2015-06-03 13:01:29 +00:00
dmiller
4a491e35d8 Check address family before loading OS fingerprints
In addition to silencing an unnecessary fatal error when nmap-os-db is
not found but user has requested -6, this should make start times a bit
more efficient, since only 1 or the other database is loaded. Patch by
Alexandru Geana

Fixes #97
2015-04-07 21:31:06 +00:00
fyodor
df26fa850c Remove --log-errors from Nmap quickref (help screen) because it has been the default behavior for a while and so does nothing 2015-04-04 01:43:08 +00:00
dmiller
a5b3aa1314 Remove references to deprecated -P* options in error message
The message stating that an unknown -P* option was used contained
references to old, deprecated forms:

-PT (now -PA)
-PB (now -PE -PA)
-PI (now -PE)

Additionally, -PR was missing.
2015-02-22 21:51:00 +00:00
dmiller
0952bed032 Merge final changes to support VS2013 build
Changes:

* Fix a collision of the name PS_NONE with a different constant in shlobj.h
* Update solution and project files for VS2013
* Update the NSIS installer to reference the VC 2013 redistributable
2015-01-17 04:35:01 +00:00
david
934de74bb0 Check string bounds looking for terminating ']'.
It was possible to trigger an out-of-bounds read by giving a port
specification with '[' but not ']'.
2014-12-20 19:12:09 +00:00
dmiller
814bf97a8f Correctly null-terminate some strings in idle_scan
Reported by Gisle Vanem: http://seclists.org/nmap-dev/2014/q4/82
2014-10-22 12:56:32 +00:00
dmiller
345bfce521 Parameterize xml_start_document and remove external DTD URI
http://seclists.org/nmap-dev/2014/q3/182
2014-08-21 20:13:59 +00:00
dmiller
5adfb3b1de Update copyright notice to 2014 2014-08-16 01:52:33 +00:00
jay
05772dd1e5 Change default output mode to show TTL info with --reason directly (no need of --reason -v). Also, remove TTL column and move TTL info to REASON column. See http://seclists.org/nmap-dev/2014/q3/289 for discussion on this 2014-08-15 14:07:25 +00:00
jay
8d5ec9e310 Reapply r33420, r33421. Fix a missing right parenthesis. https://xkcd.com/859/ 2014-08-15 12:09:22 +00:00