1
0
mirror of https://github.com/nmap/nmap.git synced 2026-01-18 20:29:02 +00:00
Commit Graph

10148 Commits

Author SHA1 Message Date
dmiller
17c3e9755e NSEdoc cleanup.
1. The first paragraph of a function's NSEdoc is used as a short
summary. Some of these were very long, so I split off a shorter summary.

2. Use asterisks (*) to denote bulletted lists, not 'o'

3. Wrap lines at 80 columns

4. a couple other spelling and formatting fixes
2014-03-10 19:01:19 +00:00
dmiller
e0a0b616b4 remove trailing whitepace from *.luadoc 2014-03-10 19:01:14 +00:00
dmiller
3dcf997d60 Fix NSEdoc errors
1. All @table blocks must have an explicit @name
2. All @field blocks must have both a name and description

Also added some more information to the creds.States table description
2014-03-08 14:02:06 +00:00
dmiller
2d06ecf73c Fix NSEdoc generation problem
@field tag names in NSEdoc must be valid identifiers, so they cannot
contain "-". As a general rule, anything that needs to be quoted like
this: mytable["field-name"] is invalid. In this case, the ajp library
had a field called "status-line", which caused NSEdoc generation to fail
when it was finally documented. This change renames it to "status_line",
which should fix the issue.
2014-03-07 23:14:55 +00:00
dmiller
944200e5dc Note unicode.lua in the Changelog 2014-03-07 19:16:37 +00:00
dmiller
fa391e1b02 New quake1-info script from Ulrik Haugen
Also added a version probe and match line.
http://seclists.org/nmap-dev/2014/q1/210
2014-03-07 17:28:40 +00:00
david
0c4cf69074 Use a separate boolean to remember whether Content-Length was set.
Previous content_length == 0 was overloaded to mean that Content-Length
was set. But that was wrong when the Content-Length was actually 0.

The error message you got when running an HTTP proxy that received
0-length POSTs was
	POST request with no Content-Length.
2014-03-07 16:57:42 +00:00
david
d5d8cd3033 Add tests for 0-length POSTs.
The non-chunked one fails for me.
FAIL HTTP POST Content-Length: 0
     Read timeout at ./ncat-test.pl line 2087.
2014-03-07 05:54:48 +00:00
dmiller
f4765340a3 Fix local variable shadowing a method. Credit Martin Holst Swende 2014-03-06 23:10:01 +00:00
dmiller
3b3131d635 Add class names to unittest.lua NSEdoc 2014-03-06 23:09:59 +00:00
dmiller
c6d4febb46 Let lltd-discovery use unicode.lua 2014-03-06 20:29:23 +00:00
dmiller
88146749f6 Add unittest.testing() to make test building conditional 2014-03-06 17:15:05 +00:00
dmiller
f8242124b8 Fix NSEdoc formatting in unittest.lua 2014-03-06 17:15:01 +00:00
dmiller
3187efdf81 Add extended-ASCII support to LM hashing
Probably only works for US-English, since it uses Code Page 437. Adding
support for other locales would require detecting or setting the locale
for the remote system, since SMB has no way to negotiate code page. In
other words, Windows systems with different locales will have different
LM hashes for the same password.

Also added some tests. Hashes confirmed by googling for them and finding
the correct plaintext.
2014-03-06 17:14:59 +00:00
dmiller
9697b6673c Add CP437 (native Windows OEM) to unicode.lua 2014-03-06 17:14:57 +00:00
dmiller
153e5f2124 unicode.lua: Add some UTF-8 decoding error checking 2014-03-06 17:14:56 +00:00
dmiller
a962973c06 Fix unicode module declaration (copy-paste error) 2014-03-06 17:14:54 +00:00
dmiller
d39efbb2d8 Fix a DeprecationWarning in zenmap with python -3
DeprecationWarning: reduce() not supported in 3.x; use
functools.reduce()

functools.reduce was added in Python 2.6
2014-03-04 21:15:52 +00:00
dmiller
9aa2d9a130 Clean up xmpp.lua NSEdoc
https://secwiki.org/w/Nmap/Code_Standards#NSEdoc_best-practices
2014-03-04 17:05:04 +00:00
dmiller
4e79e60547 Clean up smbauth.lua NSEdoc
https://secwiki.org/w/Nmap/Code_Standards#NSEdoc_best-practices
2014-03-04 17:05:02 +00:00
dmiller
f5be40278f Update sip.lua NSEdoc
https://secwiki.org/w/Nmap/Code_Standards#NSEdoc_best-practices
2014-03-04 17:05:00 +00:00
dmiller
e296cdea2a Fix some @see NSEdoc
https://secwiki.org/w/Nmap/Code_Standards#NSEdoc_best-practices
2014-03-04 17:04:58 +00:00
dmiller
4cef3889f1 Remove unused and redundant snmp.dec function 2014-03-03 22:34:25 +00:00
dmiller
d50c47d621 Remove duplicate decodeLength function 2014-03-03 22:34:23 +00:00
dmiller
a959de5685 Update asn1.lua NSEdoc
https://secwiki.org/w/Nmap/Code_Standards#NSEdoc_best-practices
2014-03-03 22:34:21 +00:00
dmiller
abb2cab7e4 Fix NSEdoc tag: @class, not @type 2014-03-03 20:12:53 +00:00
dmiller
bdb8f258ef Update ajp.lua NSEdoc
@see NSEdoc elements weren't being rendered properly, so I updated
everything. Guidelines:
https://secwiki.org/w/Nmap/Code_Standards#NSEdoc_best-practices
2014-03-03 20:04:17 +00:00
sophron
a673b79aa6 Added an entry to http-default-accounts-fingerprints that detects F5 BIG-IP router. Patch by nnposter. 2014-03-02 17:46:06 +00:00
sophron
a4a648a56b Added an entry to http-devframework-fingerprints that detects SPIP framework. Patch by Paul AMAR. 2014-03-02 17:38:57 +00:00
d33tah
bf291fdc34 chmod -x some of the files which probably shouldn't be executable. To see what's left there, call "find -executable -type f" - svn propdel 'svn:executable' file will make it non-executable. 2014-03-01 13:46:19 +00:00
henri
f20d84f9c1 Workaround to compile inline functions with MSVC v16 [Patch from Gisle Vanem]. 2014-02-24 13:16:24 +00:00
dmiller
b8b256a92b Necessary dependencies for building Ncat and Nping separately 2014-02-21 23:11:41 +00:00
dmiller
ddcfa8cc90 Spellcheck: common misspellings in the entire source tree 2014-02-21 21:10:51 +00:00
dmiller
3f5e909e8f Spellcheck on docs 2014-02-21 21:10:42 +00:00
dmiller
8e06cf53d4 http-default-accounts should return nil, not false, on failure 2014-02-20 22:10:15 +00:00
dmiller
065aa78596 Fix a crash in http-xssed when scanning an IP addr or range
http-xssed unconditionally used host.targetname, which is only set when
the target is specified as a name, not an IP address or range. Now we
prefer the targetname, but fall back to the reverse-dns name, and
finally to the IP address. Perhaps we should be more strict, if
xssed.com only allows domain names, for instance?
2014-02-20 21:37:05 +00:00
dmiller
c497ef4679 Fix a bug introduced in r32728 in upnp.lua
When payload was changed to a single string instead of a strbuf object,
calls to strbuf.dump() were not removed.
2014-02-20 21:30:05 +00:00
dmiller
a72faf3906 Spellcheck on all Python files 2014-02-20 21:22:30 +00:00
dmiller
1575c63d7d Spellcheck for Ncat, Nping source files 2014-02-20 21:22:22 +00:00
dmiller
3f0d0c16f9 Spellcheck on Nmap, Nsock, Nbase source files 2014-02-20 18:44:12 +00:00
dmiller
b8873f42cd Better error reporting for smb-mbenum
Check for error 71 (0x47), which means the server is simply not a master
or backup browser and will not respond.

Also teardown the SMB session as far as it has been established, to be
nice.
2014-02-19 22:35:34 +00:00
dmiller
b3b5f8c377 Fix format-string bug: ./nmap -sC --script-args '%n' -ddd 2014-02-19 22:14:18 +00:00
dmiller
6e3980733e Use unicode library for msrpc/smb 2014-02-19 22:14:16 +00:00
dmiller
1ff0062589 Use unicode library for NTLM in sasl.lua 2014-02-19 22:14:14 +00:00
dmiller
743c90c24a Use nsedebug.tostr in unittest to more clearly show how tests fail. 2014-02-19 18:32:25 +00:00
dmiller
f17cc56bf9 New utility functions for transcoding to and from Windows Unicode
Windows uses UTF-16 little-endian. Since this is a common use case,
utility functions are provided such that this:

    x = unicode.utf16to8(v)

is equivalent to this:

    x = unicode.encode(unicode.decode(v, unicode.utf16_dec),
    unicode.utf8_enc)

but faster (fewer intermediate tables)
2014-02-19 18:32:23 +00:00
dmiller
a76990b9ae Fix off-by-one error in unicode.decode.
Would fail to decode the last character in a string.
2014-02-19 18:32:21 +00:00
dmiller
44a006a7cf Let json.lua use unicode.lua for utf8_enc 2014-02-19 17:08:31 +00:00
dmiller
1273cb4200 New unicode.lua library. Supports utf-8 and UTF-16 2014-02-19 17:08:30 +00:00
dmiller
210d50a1d9 Add table_equal test to unittest.lua
Checks that 2 tables have the same length and list values.
2014-02-19 17:08:27 +00:00