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

37 Commits

Author SHA1 Message Date
david
0804560126 Limit scope of recvfrom address. 2011-09-03 18:48:12 +00:00
david
52de87b974 Use a sockaddr_storage for recvfrom in get_rpc_results.
Previously it was hardcoded to be sockaddr_in, which is obviously wrong
for IPv6. This was only used to filter out packets from other than the
host we are scanning. It may have still been succeeding by accident if
part of the IPv6 address had the bytes 00000000, because for me the port
number is at the same offset in sockaddr_in and sockaddr_in6, and
target->v4host().s_addr returns 00000000 for an IPv6 host.
2011-09-03 18:48:11 +00:00
david
e6bb524f18 Use u32 rather than unsigned long to define RPC packet structure.
RPC scan was broken on some 64-bit architectures because unsigned long
is 8 bytes, not 4.
2011-09-03 18:08:20 +00:00
david
523c4f7104 Remove -sR o.rpcscan handling; make -sR an alias for -sV. 2011-03-12 18:20:09 +00:00
fyodor
86e59a8c4e Update copyright statements from 2010 to 2011 2011-01-21 00:04:16 +00:00
david
7653cf7d4a Move COPYING.OpenSSL to OpenSSL.txt, update copyright notices to match. 2010-10-30 03:01:50 +00:00
luis
da126c8b78 Merged nmap-dedup branch from nmap-exp/luis/nmap-dedup. This completes the Nmap/Nping code de-duplication phase. 2010-06-22 17:24:34 +00:00
fyodor
1aecac420f Update copyright year from 2009 to 2010 2010-05-03 21:20:25 +00:00
david
7db7da0007 Merge again from /nmap-exp/david/nmap-mem; this fixes a couple of bugs. 2009-12-20 03:22:19 +00:00
david
1c6030709b Revert r16307:16309, the merge from nmap-mem. I just found a
segmentation fault which I am investigating.
2009-12-19 22:49:16 +00:00
david
b838242e01 Merge from /nmap-exp/david/nmap-mem. This brings in two memory-reducing
changes. The first is that Port objects don't allocate memory for
service and RPC results unless that information is set. This reduces the
size of a bare Port from 92 to 40 bytes on my machine. The second change
is that PortList now has the notion of a "default port state," which is
the state of any ports that didn't receive a response. These ports don't
need an allocated Port object, which saves a lot of memory in scans
where most ports didn't get a response.
2009-12-19 21:26:14 +00:00
david
e2315ae075 Remove the unused Port::owner member. 2009-11-20 20:17:33 +00:00
david
e0870187de Remove a test
if (tcp_rpc_socket > max_sd)
	  max_sd = tcp_rpc_socket;
The condition is always true because max_sd is initialized to -1 and that block
of code is entered only if tcp_rpc_socket > -1. It looks like the kind of thing
that would be managing a large set of sockets for select, but here we're only
selecting on one socket at a time. This was suggested by Lionel Cons.
2009-11-12 16:00:16 +00:00
david
6662fc1cca Reindent the get_rpc_results function. 2009-11-11 03:53:12 +00:00
luis
a5ca31db9e Replaced nmap's hex dump functions with new hexdump() included in nbase. Before
Nmap used two functions: one of them, hdump(), just printed raw hex bytes 
(no ASCII equivalents) and the other one, lamont_hdump() had a bug when 
printing buffers where bufflen%16==3. A new function has been implemented 
from scratch, that basically produces the same output as Wireshark. 
Output looks like this:

0000   e8 60 65 86 d7 86 6d 30  35 97 54 87 ff 67 05 9e  .`e...m05.T..g..
0010   07 5a 98 c0 ea ad 50 d2  62 4f 7b ff e1 34 f8 fc  .Z....P.bO{..4..
0020   c4 84 0a 6a 39 ad 3c 10  63 b2 22 c4 24 40 f4 b1  ...j9.<.c.".$@..

Changes:

- The new hexdump() function has been added to nbase.
- Old hdump() and lamont_dump() have been removed from nmap's code.
- A wrapper to the new hexdump(), called nmap_hexdump(), has been added
  to nmap's utils.cc. The wrapper basically prints the buffer returned 
  by hexdump() using nmap's log_write() function.
2009-08-25 18:09:19 +00:00
josh
df71e36084 Updated uses of the ctype function to support explict casting of the arguments
to (int)(unsigned char).
2009-08-06 15:10:00 +00:00
fyodor
d0e21e1d03 Suggest that people send patches to nmap-dev rather than to me directly 2009-04-15 00:37:03 +00:00
fyodor
eccc235d5a Increase copyright year to 2009, simplify/reword some derivative works text, and remove a confusing clause about selling proprietary front-ends to Nmap 2009-03-31 04:16:12 +00:00
kris
e36c7e3e9a change sizeof(struct sockaddr_storage) to real sockaddr len 2008-12-22 00:05:22 +00:00
fyodor
779b96a197 trivial copyright text tweak: filename nmap-os-fingerprints has changed to nmap-os-db 2008-05-22 20:45:32 +00:00
fyodor
10b54b773b minor license template updates from Kris--fix gnu.org link to GPLv2 (moved) and openssl license filename (COPYING.OpenSSL) 2008-05-05 04:10:00 +00:00
fyodor
1accc12fb2 fix typo in legal header found by Leigh Zhao (missing word: of) 2008-02-28 18:52:06 +00:00
fyodor
29c912f394 URL change from http://insecure.org/nmap/* to http://nmap.org/* 2008-01-17 07:22:03 +00:00
kris
1a5657511f adding IPv6 support to RPC scan 2008-01-15 00:50:26 +00:00
fyodor
8220c8a42f update copyright line at the top of files from 1996-2006 to 1996-2008 2007-12-22 06:32:03 +00:00
fyodor
8dc9673928 merge soc07 r5085 - Changing bare printf()s to log_write(LOG_PLAIN,)s because these were always printed even when things like XML and greppable output were sent to stdout (e.g. -oX -). This also adds o.scriptTrace() to make --script-trace behave more like --packet-trace and --version-trace. Nsock tracing was done unconditionally in NSE, and that has been changed to only be done when o.scriptTrace() is true. 2007-08-11 05:13:16 +00:00
fyodor
8d74bbcd8a merge soc07 r4871:4884 and r4888 - renaming __FUNCTION__ to __func__ and changing hardcoded func names to __func__ 2007-08-11 04:06:09 +00:00
fyodor
5e3bb361f2 merge soc07 r4860 - Add verbose data file path reporting. Some more changes might be coming, for example to change the conditions under which this information is displayed. 2007-08-11 03:59:18 +00:00
fyodor
58522c59f6 merge soc07 r4822 - Reduce the number of build dependencies. 2007-08-11 03:35:46 +00:00
kris
cc14c538ad Removing extraneous newlines (sometimes up to 9 of them) from ends of a few files 2007-02-04 02:53:29 +00:00
kris
71ed5177c4 A couple of small changes with filenames in file headers. 'output.c' -> 'output.h', 'rpc.cc' -> 'nmap_rpc.cc', 'rpc.h' -> 'nmap_rpc.h' 2007-01-27 02:34:13 +00:00
fyodor
b361685be8 NSE committed 2006-12-11 00:34:26 +00:00
fyodor
b28d51167c Minor source code header improvements 2006-08-25 01:47:49 +00:00
fyodor
a403864351 Replace file headers, mostly to update copyright to 2006 2006-08-24 04:43:50 +00:00
fyodor
76ab1500b3 make a ton of global symbols static 2006-03-05 23:59:46 +00:00
fyodor
d187c68017 blah 2005-10-01 23:50:27 +00:00
fyodor
26ce3d66f4 get rid of silly top-level trunk dir 2005-04-11 22:34:19 +00:00