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

275 Commits

Author SHA1 Message Date
rewanth
6ee953a5ff Removes trailing spaces in 69 files. Closes #971. 2017-08-23 08:52:40 +00:00
dmiller
a66e75173e Keep resolved, scanned addresses separate from unscanned addresses. 2017-08-07 14:25:13 +00:00
dmiller
9c7ea727a7 Update license terms for 2017 2017-06-07 12:32:38 +00:00
dmiller
e09cb62439 Only report warning about ratelimits when filtered ports exist 2017-05-02 20:36:08 +00:00
dmiller
e813de759a Reduce use of utils.h for error functions 2017-04-20 22:39:08 +00:00
dmiller
891c3be3b9 remove tcpip.h from other headers' includes 2017-04-19 13:53:57 +00:00
dmiller
b4924eb362 Avoid warning about --defeat-rst-ratelimit when TCP scan was not even done. Fixes #727 2017-03-05 04:25:39 +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
062d272d0f Make --open imply --defeat-rst-ratelimit 2016-11-28 17:11:01 +00:00
dmiller
7128753730 Randomly ask for user submission of already-matching IPv6 fingerprint from weak groups 2016-09-30 05:30:44 +00:00
dmiller
9370f5bd5d Strip carriage returns (\r) from output to prevent spoofing 2016-09-21 03:55:12 +00:00
tudor
7f1ec2b806 o.numhosts_scanned and o.numhosts_up are now printed as unsigned ints with %u 2016-08-09 14:31:59 +00:00
tudor
c860732097 Limited unnecessary calls to alloc_vsprintf 2016-08-07 16:19:53 +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
vincent
0f22680426 Correct format string specifiers
The formats has been tested and verified on Mac OS X 10.8.5,
Mac OS X 10.11.5 and Ubuntu 14.04 LTS, all on x86_64 machines
and OSs. It mainly silences warnings. There were no warnings on
Ubuntu but a few on Mac OS, so the fix is intended to silence
warnings on Mac OS whithout triggering new warnings on other OSs.
Example of warnings previously encountered:

netutil.cc:2828:74: warning: format specifies type 'unsigned short'
but the argument has type 'int' [-Wformat]
2016-07-01 11:44:26 +00:00
dmiller
6e33d6ac3c Bump date in copyright headers 2016-04-04 15:38:44 +00:00
dmiller
e124565c58 Use time_t instead of long and double for storing uptime
Fixes #275.

This results in fewer casts and less subtraction than the previous
method, and should still be portable. Only division and subtraction and
difftime are performed on the value, so it will not overflow. And the
TCP timestamp itself is a 32-bit value, so it can't refer to a time
farther in the past than the 32-bit epoch. One explicit cast (to long
long) is used in order to ensure the format string can handle any
conceivable value according to the compiler and avoid a warning message.
2016-01-13 20:53:39 +00:00
dmiller
dd0050598b Print service info for unlisted ports when service tunnel is detected 2015-12-20 05:34:56 +00:00
dmiller
5e47450bdc Use forward-declaration of class FingerPrintResults in Target.h 2015-06-30 04:04:51 +00:00
henri
b55ff2d68f Don't associate nsock logging info to a nspool.
Make current loglevel and current log callback global
to the library. Attaching them to the nsock pool doesn't
bring any benefit and prevents from logging activity in
code sections that don't have access to a pool (such as
proxy chain specification parsing).

Updated external calls and nsock tests accordingly.
2015-06-27 08:21:53 +00:00
dmiller
638a123ba6 Move osscan structs from global_structures to osscan2.h 2015-06-23 15:53:05 +00:00
dmiller
68409b2226 Update copyright date to 2015 2015-06-03 13:01:29 +00:00
dmiller
c0628fd141 Report IPv4 and IPv6 addresses resolved for each host
Previously, we would only request IPv4 addresses by default, or only
IPv6 when scanning with -6. Now, we'll request both (by not passing an
address family in the hints to getaddrinfo) and report them all in the
"Other addresses" line. This should encourage more users to scan with
-6. Additionally, it allows us to catch and report attempts to scan
IPv6-only hosts via IPv4, where previously we would just say "Failed to
resolve"

Closes #76
2015-03-11 04:14:26 +00:00
dmiller
54c737a377 Update location of fingerprint submitter. 2015-02-12 05:02:47 +00:00
dmiller
d0b360b1a2 normalize capitalization for ttl output 2014-09-03 04:49:48 +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
fyodor
f6f59a7cd7 Auto regeneration with latest template files, etc. 2014-08-13 22:57:43 +00:00
jay
d4cf544df6 Fix a missing bracket at the end of the IMPORTANT NMAP LICENSE TERMS part in each file 2014-08-02 19:29:50 +00:00
jay
d70f5b364a Show TTL in default output if "--reason -v" is asked for. 2014-07-22 01:55:04 +00:00
dmiller
1320ea9ca2 Remove leftover debugging statement 2014-06-26 04:01:44 +00:00
dmiller
a0a94f9303 Properly handle interfaces with NULL addresses
Some vsnprintf implementations (or perhaps some compiler options?) don't
like formatting NULL as %s, and will segfault (ran into this with
libstdc++ on Solaris). We don't get bug reports because at least some
(including mine on Ubuntu) will simply format it as "(null)".

This patch adds explicit checking for NULL to avoid the segfault
condition.
2014-06-26 02:53:57 +00:00
d33tah
a80c90608c sed -i 's/if ( /if (/g' *.cc *.h; sed -i 's/for ( /for (/g' *.cc *.h; sed -i 's/( /(/g' nmap_amigaos.h tcpip.h service_scan.cc
There's still quite a lot of code like this, nse_openssl.cc being most
messy IMHO. Also, I left out "if( something )" syntax.
2014-06-25 15:40:54 +00:00
d33tah
421176fc00 Get rid of double newline at the EOF I accidentally introduced in the
last commit.
2014-06-18 11:30:02 +00:00
dmiller
3f0d0c16f9 Spellcheck on Nmap, Nsock, Nbase source files 2014-02-20 18:44:12 +00:00
fyodor
74ebf1c892 remove an orphan parameter from fatal() call. Problem noted by Gisle Vanem 2014-02-14 06:17:53 +00:00
dmiller
c9714990c7 Remove trailing whitespace from C/C++ files
https://secwiki.org/w/Nmap/Code_Standards
2014-02-12 20:25:51 +00:00
d33tah
4816358475 Replace all tab characters at the beginnings of lines with 8 spaces.
Mixed indentation annoyed my vim.
2014-01-05 19:14:26 +00:00
dmiller
866db7eea3 Revert r32528, was not tested on Windows 2013-11-27 13:32:05 +00:00
dmiller
9c36367eea header file cleanup
see http://seclists.org/nmap-dev/2013/q4/168

Move some includes out of nmap.h: nmap.h gets included lots of places,
and unconditionally included math.h, ctype.h, errno.h, stdio.h,
sys/stat.h, fcntl.h, sys/types.h, and stdarg.h. This commit moves those
includes into the .cc files where they are necessary and out of nmap.h

Remove redundant include global_structures.h, included from nmap.h

Removed redundant code included from nmap.h

Removing #include nbase.h when nmap.h is included (redundant)

Remove duplicate #include lines

Add ifndef guards to a few .h files
2013-11-26 20:55:29 +00:00
d33tah
ccd0c02a4c Add a lacking space in the license comment. The command I used to do this is:
for file in `grep "* including the terms and conditions of this license text as well.       \*" * -r --files-with-match `; do sed "s/\* including the terms and conditions of this license text as well.       \*/* including the terms and conditions of this license text as well.        */g" -i $file; done
2013-09-11 19:06:20 +00:00
fyodor
6e01ecd452 Update an email address, fix a typo, and slightly reword a sentence. 2013-07-30 00:02:00 +00:00
fyodor
83fb10ec56 Update the Nmap copyright/license files. This isn't the new Nmap Public Source License we've been discussing on the list, but rather just a 'quick patch' to hopefully prevent some of the abuse we've been seeing from companies lately. More details on the changes will be posted to the dev list. Also, the copyright year was updated to 2013 (which is the only change to Nsock license statements). 2013-07-28 22:05:05 +00:00
david
6238087e9b Compare string contents, not pointer values.
This bug was introduced in r30334. We want to compare the contents of
the strings, not their addresses. This bug caused host script results to
be printed in arbitrary, perhaps not even well-defined, order.
2013-06-14 17:26:43 +00:00
david
7684b43072 Formatting. 2013-06-13 15:22:17 +00:00
david
8c7e0881ec Remove misleading comments.
There is more than just sorting going on here; it's also whether some
output is written.
2013-06-13 15:22:13 +00:00
david
13abd4df8a Restore empty rpc_info field to gnmap port output from r29619.
Patch by Daniel Miller.
2013-04-17 22:48:31 +00:00
david
8e20e6a65b Show route metrics in --iflist. 2013-02-01 05:01:58 +00:00