1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-08 13:41:29 +00:00
Commit Graph

26 Commits

Author SHA1 Message Date
kris
740318cee9 Updating ip_is_reserved(): the last IPv4 address blocks (102-104/8, 179/8 and
185/8) have been allocated to the RIRs
2011-02-04 03:06:57 +00:00
kris
c95e5d797b updating ip_is_reserved(): 39/8 and 106/8 allocated today 2011-02-01 00:19:56 +00:00
fyodor
86e59a8c4e Update copyright statements from 2010 to 2011 2011-01-21 00:04:16 +00:00
kris
39ac0e4eda relatively large ip_is_reserved() update: 5/8, 23/8, 37/8 and 100/8 allocated 2010-12-04 00:16:38 +00:00
kris
2e838599c3 updating ip_is_reserved(): 105/8 allocated 2010-11-16 04:54:35 +00:00
david
7653cf7d4a Move COPYING.OpenSSL to OpenSSL.txt, update copyright notices to match. 2010-10-30 03:01:50 +00:00
luis
d0a4d0ad50 Moved function max_sd() to libnetutil. Also, two new helper functions have been added. 2010-10-20 15:57:50 +00:00
kris
5e9277cc3a updating ip_is_reserved(): 36/8 and 42/8 allocated 2010-10-19 19:55:03 +00:00
batrick
80672911fd Use const char *. 2010-08-28 16:01:35 +00:00
kris
57664a51cf Committing MTU-related changes:
* Adding path-mtu.nse for Path MTU Discovery
* Nmap now stores the MTU for interfaces (from SIOCGIFMTU or libdnet)
* Scripts can access the MTU for host.interface via host.interface_mtu
* Nmap prints the MTU for interfaces in --iflist
2010-08-24 01:47:12 +00:00
kris
9b4f8013e8 updating ip_is_reserved(): 49/8 and 101/8 allocated 2010-08-06 11:29:02 +00:00
kris
35dd4e1377 Don't retry in Sendto() if errno is EMSGSIZE: sleeping for a few seconds
won't shorten the packet.
2010-08-02 07:41:53 +00:00
kris
643d3eb9ff o Fixed the fragmentation options (-f, --mtu) which broke in 5.35DC1.
Instead of sending multiple fragments, Nmap would just send the
  original whole packet instead.  In some circumstances, Nmap would
  fail to send on interfaces with low MTUs (such as SLIP lines) with
  no way to bump down packet sizes for transport. [Kris]

It looks like this has been broken in trunk since merging libnetutil,
and since r18037 in the dedup branch.
2010-07-28 22:34:12 +00:00
david
8a5d27fae8 Include <sys/sockio.h> in libnetutil/netutil.cc. This is necessary to
compile on OpenSolaris according to
http://blogs.sun.com/sdaven/entry/nmap_5_35dc1_compile_on.
2010-07-26 22:19:23 +00:00
fyodor
5539c9e39e Change NETINET_IN_SYSTEM_H definitions to NETINET_IN_SYSTM_H (missing the final E) because that is how the actual include filename is spelled. Also removed instances of HAVE_NETINET_IN_SYSTEM_H since they aren't used 2010-07-14 05:43:19 +00:00
kris
17b7ec4622 Now this should fix the last commit, but for Windows (and whatever else sucks
and doesn't use normal socket headers).  Untested now, but everything should
be guarded like elsewhere.  I forget this stuff until after I type ci...
2010-07-12 22:12:09 +00:00
kris
b7627cb96e Fix NetBSD compilation. These headers should really be included anyway, they
aren't just some NetBSD quirk.
2010-07-12 22:01:34 +00:00
david
62c2276755 Properly match up directly connect routes with alias interface addresses
in getsysroutes_proc. This was already being done for non–directly
connected routes, those with a gateway. Victor Rudnev reported this bug.

The /proc/net/route file doesn't contain alias qualifications so we must
match them up after the fact with the interface table. When the gateway
address isn't set, use the route destination for matching instead.

For example, with these interfaces and routing table,

eth0      Link encap:Ethernet  HWaddr 00:50:BF:16:11:61
          inet addr:192.168.1.21  Bcast:192.168.1.255 Mask:255.255.255.0

eth0:1    Link encap:Ethernet  HWaddr 00:50:BF:16:11:61
          inet addr:192.168.0.21  Bcast:192.168.0.255 Mask:255.255.255.0

Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0
192.168.0.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0

nmap --iflist before this commit:

DEV    (SHORT) IP/MASK         TYPE     UP MAC
eth0   (eth0)  192.168.1.21/24 ethernet up 00:50:BF:16:11:61
eth0:1 (eth0)  192.168.0.21/24 ethernet up 00:50:BF:16:11:61

DST/MASK       DEV    GATEWAY
192.168.1.0/24 eth0
192.168.0.0/24 eth0

nmap --iflist after this commit:

DEV    (SHORT) IP/MASK         TYPE     UP MAC
eth0   (eth0)  192.168.1.21/24 ethernet up 00:50:BF:16:11:61
eth0:1 (eth0)  192.168.0.21/24 ethernet up 00:50:BF:16:11:61

DST/MASK       DEV    GATEWAY
192.168.1.0/24 eth0
192.168.0.0/24 eth0:1
2010-07-04 17:42:49 +00:00
david
9d1a797c8f Revert r18424. This was mean to fix OpenBSD compilation but it broken on
Windows because of a lack of <sys/socket.h>. We have a request in to the
original reporter for more information and a cleaner fix.
2010-06-30 00:11:07 +00:00
luis
8aa0a4b5fe Fixed compiler warning caused by a possible uninitialized var 2010-06-28 07:47:35 +00:00
luis
c32d0c6d66 Fixed a couple of compiler warnings, caused by signed vs unsigned comparisons 2010-06-28 07:46:00 +00:00
luis
6e0e3964bb Fixed compilation problem in OpenBSD 4.7. This was reported and fixed by Lori 2010-06-28 07:44:28 +00:00
david
0a3c6f1fc7 Include <sys/types.h> before <net/if_arp.h> in netutil.cc. I needed this on OS
X when compiling against the 10.4u SDK.
2010-06-24 15:04:16 +00:00
david
a468082429 Remove DOS line endings from some lines in netutil.cc. 2010-06-24 14:34:33 +00:00
luis
d11edeb3e7 Changed send_frag_ip_packet() to make sure it accepts big MTU values, and fixed the format specifier, which was printing a signed integer when it should print an unsigned one 2010-06-22 18:22:54 +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