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

594 Commits

Author SHA1 Message Date
kris
abbaffe21c Updating with Jan '07 IANA IPv4 assignment changes. And the previous IANA patch from Mike Phipps was, in fact, wrong. Apparently he was undoing my previous IANA patch (which Fyodor committed in r4251) 2007-02-09 01:28:58 +00:00
fyodor
5fbc63cc22 revert last patch -- Kris tells me the new assignment numbers may be wrong 2007-02-09 00:17:38 +00:00
fyodor
2be2d61233 MS exchange probe improvements from Matt Selsky 2007-02-08 20:23:21 +00:00
fyodor
7c9805b954 IANA patch from Mike Phipps 2007-02-07 21:06:29 +00:00
kris
6108931bf9 Just updating my email address in the CHANGELOG. My old one was listed from some of my older patches. 2007-02-04 03:16:04 +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
692f904579 Print IP addresses in ippackethdrinfo() in tcpip.cc when there's an unknown protocol (like with -sO) 2007-02-04 02:12:59 +00:00
kris
c0bb3fa376 Just removing a few empty private access specifiers ('private:' is there, but it's not specifying anything) 2007-02-04 01:07:36 +00:00
kris
ddd6366540 Change max protocol count when ignoring states. The IPProto Scan wasn't taken into account when figuring out how many ports/protocols should be in a given state before ignoring them. For me in most cases, -d caused every protocol to be listed because most were open|filtered and the -d set the max to a value a lot larger than 255. Now for the same hosts, it takes -d3 to print them all. 2007-02-03 21:29:13 +00:00
kris
395b4d2150 Staying on the safe side when matching TCP flags on one part in scan_engine.cc. Instead of testing th_flags == TH_SYN|TH_ACK, it tests if (th_flags & TH_SYN|TH_ACK) == TH_SYN|TH_ACK. It's looks like it's done 'correctly' everywhere else. I can't really think of a real situation where we'd recieve any extra flags when doing a SYN scan, but we could (and it's better than having a false negative anyway). 2007-02-03 04:15:18 +00:00
kris
7d778b51c9 Just fixing a couple typos in comments in scan_engine.cc 2007-02-03 03:57:35 +00:00
kris
5036877865 Remove some duplication in get_pcap_result() in scan_engine.cc. probe->protocol() is all ready checked against ip2->ip_p earlier (the two I'm removing indirectly check against ip2->ip_p: look at the removed part and what ip2->ip_p is tested against in the surrounding if()s). Then a little lower in the function, that whole if() block can be removed because it's the same as what's done in that switch() block. The same error() and hdump() are used in the default case. I could've kept the if(), but this keeps is simple. 2007-02-02 02:33:20 +00:00
kris
2ae3144aa7 Merging my input buffer flushing patch for nmap_tty.cc. This uses tcflush() for UNIX and FlushConsoleInputBuffer() for Win32. The more keys that have been queued up, the more of a difference these functions seem to make. That's not to say that they're slow when there's just one :) I've tested it on Windows XP and my Linux box, and it works great on both. If it actually causes some problems, it won't be hard to reverse. 2007-02-01 14:07:02 +00:00
kris
ff6055805c A small change in ordering in the configure script. We'll now test for inline and '' _after_ the host type testing. is tested for when doing the inline stuff, but doesn't seem to be set until (or can be reset during) the host type testing. 2007-02-01 03:28:58 +00:00
kris
6998ddd019 Removing mswin32/netinet/tcp* and udp*. Thanks to my dnet header patch (r4379), we're able to safely remove all of these files and then remove their references from mswin32/winclude.h. tcp_var.h wasn't used anywhere, and all of the others are only used in libpcap/. Since these NETINET files are only used for Windows, and WinPcap is required for that, this isn't a problem. I've tested it on Windows XP with MS VC++ Express 2005. 2007-01-31 23:37:18 +00:00
kris
176046784b Use ipid parameter for build_icmp_raw() and build_igmp_raw() instead of get_random_u16() when calling build_ip_raw(). 2007-01-30 00:35:44 +00:00
kris
76c8efc086 Removing the IPIP header sending with -sO from r4403. This turned out to be less useful than I originally found it to be. 2007-01-29 18:02:28 +00:00
kris
3695115c65 Changed location of IP options + root privs check in NmapOps.cc. It's now just checked along with the other things that require root privileges, and now uses privreq instead just saying 'you must be root'. 2007-01-29 03:22:15 +00:00
kris
e326bc0266 Fix --max-os-tries and --max-rtt-timeout options. There was a typo which caused two optcmp()s to be checking for max-rtt-timeout instead of one for that and one for max-os-tries. Since the first one was supposed to check for max-os-tries, --max-rtt-timeout has been setting max-os-tries. This meant there was no way to set max-rtt-timeout, and --max-os-tries always failed with an error message. 2007-01-28 13:18:32 +00:00
fyodor
a721fd621d fix typo 2007-01-28 03:46:00 +00:00
kris
d814edc141 Adding a couple changes to the CHANGELOG 2007-01-28 02:59:44 +00:00
kris
c2427f32d3 Fixed IPProto Scan on localhost when using --data-length to add at least 8 bytes of data. There is a check to see if the packet is at least 28 bytes long (IP header and 8 bytes of data), and if it's at least that big it's considered good. So if the protocol matches, it's considered open. The problem was we didn't check for our own probes, so if we scan localhost with --data-length >=8, everything was labeled open. 2007-01-28 02:25:27 +00:00
kris
6d4ef2aa7e Fix the IPProto scan for UDP. Now we check for ICMP Port Unreachable and call it open if we get one. This was coming up open|filtered, and sometimes filtered before. 2007-01-27 20:09:14 +00:00
kris
1e3760a397 Start sending a valid encapsulated header with IP-in-IP with -sO. Hosts respond more when a valid header is sent. I kept getting open|filtered for this, and now I get open. It's a lot like my IGMP patch from r4361 2007-01-27 04:36:24 +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
kris
811df5594f Remove inet_aton() checks from configure and HAVE_INET_ATON from config.h.in 2007-01-27 00:29:47 +00:00
kris
4cbb311bc4 Change __BSD_SOURCE references to _BSD_SOURCE. The __FAVOR_BSD and __USE_BSD have double underscores in front, the *_SOURCE only have one. 2007-01-26 22:32:42 +00:00
kris
81cb9193e8 Change a couple ISPRINT() macro uses to nse_isprint() in nse_string.cc. nse_isprint() just uses ISPRINT() right now anyway. 2007-01-26 00:04:54 +00:00
kris
b8b7e2c47a Tiny change: icmp_hun.ih_void -> icmp_void in osscan2.cc. icmp_void is #define'd to that ugly thing 2007-01-24 19:09:04 +00:00
kris
69754e8311 Use dnet headers for TCP and UDP. This allows us to remove netinet tcp.h and udp.h references, the udphdr_bsd stuff, and the TH_ECE/TH_CWR #defines in tcpip.h. That was easy, but we (Fyodor and I) came to the conclusion that IP and ICMP aren't worth the hassle to switch (I was testing TCP, UDP and IP in my branch). The struct icmp_hdr in dnet isn't setup anything like what we're using now. Then, struct ip_hdr uses ip_addr_t (typedef'd to uint32_t in that ip.h) instead of struct in_addr for the IP addresses, and that would require some dnet modifying to work right. We might be able to come up with some elegant solution for IP, but probably not for ICMP. For now, they're still left up to netinet (or tcpip.h). 2007-01-23 05:29:59 +00:00
doug
cda944c804 oops 2007-01-23 04:01:10 +00:00
doug
d26e54847b UDP --badsum fix 2007-01-23 03:28:03 +00:00
doug
a869a1df8f UDP --badsum fix 2007-01-23 03:17:32 +00:00
kris
d13d4a869e Added some of my changes to the CHANGELOG 2007-01-23 01:09:31 +00:00
kris
8471833bac Remove duplicate #define __FAVOR_BSD in nmap.h 2007-01-21 16:40:46 +00:00
kris
ba8defb238 Prevent empty 'Fetchfile found' message (with -d2) from nmap_fetchfile() when it wasn't actually found. 2007-01-20 23:48:18 +00:00
kris
24e30769e8 Merging my UDP localhost patch. It fixes the UDP scan on localhost picking up it's own port. It also fixes the TCP one so that it doesn't print a message (with -d) about receiving a response with unexpected flags (like getting a SYN for a SYN scan because it's our port). The problem was that the IP ID wasn't ntohs()'d while checking for this, so we still saw our port on UDP. I simply copied this to the TCP part to avoid the message. 2007-01-20 22:15:49 +00:00
kris
6da0b2a534 Merging my --scanflags change. This allows 'ECE', 'CWR', 'ALL' and 'NONE' to be used. They've all been possible to set using a number, but I like names more :) 2007-01-19 20:14:36 +00:00
kris
928750ce05 Fix some typos, one in output. IPPROTO_TCP -> IPPROTO_IP (2), extre -> extra, /etc/protocol -> /etc/protocols 2007-01-19 01:39:03 +00:00
fyodor
0a4e660bdd fix some typos (applie -> apple) reported by Matthew Boyle 2007-01-19 00:05:41 +00:00
kris
9ff574d50e Merging my IGMP -sO patch. This adds build_igmp_raw() to easily build IGMP packets and uses it for -sO. Systems respond more when these packets are sent with an actual IGMP header. The RFC says they MUST verify the checksum, so that's most likely why I always got open|filtered instead of open. Since the different IGMP types all seem to have the checksum in the same place in the packet, it should at least tell us if it's supported or not even if the rest of the header is bogus (because the rest of the header has changed a little bit between the versions). 2007-01-17 17:40:16 +00:00
kris
2ce87a0250 Merging my -sO -p-XX, rangestart=0 patch. Also (new change) if it's like -sO -pXX-, we cut off rangeend at 255 instead of 65535 so we don't have to do the extra looping later in a while(). IP Proto scanning cant be used along with TCP or UDP scans so cutting it off here works better. 2007-01-16 17:42:07 +00:00
fyodor
662cc464d0 just moved an entry 2007-01-16 11:01:55 +00:00
kris
4e4924b408 A few changes to fileexistsandisreadable() (I can't leave this thing alone, can I? :)). First, 'status' is initialized to 0 instead of -1 because if stat() succeeds, but 'pathname_buf' isn't readable at all, this function was returning that -1 (which it shouldn't because the comment says 0, and nmap_fetchfile() checks for a non-zero return value and assumes it found something, but it wasn't breaking anything). Also, access() is now only called once and then the directory-check is done. And finally the comment now explicitly states that 1 is returned if it's readable and not a directory instead of just non-zero. This also just uses S_ISDIR() for testing for a directory, so it might actually be a portability enhancement because WIN32 apparently doesn't have S_ISDIR() and in nbase.h it's defined to something different just than ANDing with S_IFDIR. 2007-01-15 18:24:47 +00:00
kris
01fd967479 This may sound weird, but I just cut nse_macros.h in half. The same thing was put in twice, so I deleted the second one (half of the file). I split it into two files/halves to test it out, and a diff came up empty. So yeah :) 2007-01-12 21:33:58 +00:00
kris
4d190f3751 Allow environment variable NMAP_UNPRIVILEGED to be equivalent to --unprivileged as NMAP_PRIVILEGED is to --privileged. 2007-01-12 02:31:47 +00:00
kris
889a40a1e1 Just fixed a couple of typos. 'msx-scan-delay' -> 'max-scan-delay' under the Timing Report (-d), and 'Mapps' -> 'Maps' in a comment. 2007-01-11 20:18:42 +00:00
kris
06e35a0c43 2007-01-11 16:07:04 +00:00
fyodor
715b600a0f Added a bunch of nmap-services port listings from Stephanie Wen (goddessstephie) 2007-01-10 20:51:52 +00:00
diman
65d08549c7 Hopefully final --iflist bug
the routes are now displayed correctly
2007-01-08 21:56:22 +00:00