indent and prefix before each line, not just at the beginning. If the
indent was ">>>>", then formatting the line "AB\nCD" would result in
| >>>> AB
|_CD
Now it will be
| >>>> AB
|_>>>> CD
Some script were working around this by relying on an invisible blank
first line and manually indenting following lines.
This should be handled by the generic case, and I don't think it was
used anyway because the logic was wrong:
if(indent == nil and #data == 1 and type(data) == 'string' and not(data['name']) and not(data['warning'])) then
return data[1]
end
This seems to be checking for a one-element table whose single element
is a string. But the test "#data == 1 and type(data) == 'string'" is
actually testing for a one-byte string. I think this is supposed to be
"type(data[1]) == 'string'", but anyway it should be handled by the
generic case.
point seconds since the epoch, and add clock_ms() and clock_us() to stdnse
for convenience (millisecond and microsecond).
qscan.nse now provides microsecond resolution.
it was returning an empty string, causing blank output entries for
scripts with no output:
80/tcp open http
|_citrix-enum-apps-xml:
|_citrix-enum-servers-xml:
| http-headers:
| Date: Sun, 31 Jan 2010 19:28:13 GMT
| Server: Apache/2.2.3 (CentOS)
| Accept-Ranges: bytes
| Content-Length: 739
| Connection: close
| Content-Type: text/html; charset=UTF-8
|
|_ (Request type: HEAD)
|_http-date: Sun, 31 Jan 2010 19:28:14 GMT; +1s from local time.
|_html-title: Go ahead and ScanMe!
1) I wrote a function that formats output from scripts in a consistent way. Although we haven't really come to a concensus on how it should look yet, it's easy to change when we do.
2) New script: smb-enum-groups.nse. Enumerate the local groups on a system and their membership.
now a script is limited in parallelism to working on one socket at any
time. A script can now create a worker thread that will be capable of
doing work on sockets in parallel with the parent script. See [1] for
more information.
This patch also comes with condition variables that are similar to
POSIX condition variables. They are used in the same fashion as
NSE's mutexes (nmap.mutex).
[1] http://seclists.org/nmap-dev/2009/q4/294
INFO processing file `nselib/datafiles.lua'
ERROR undefined handler for tag `type'
INFO processing file `nselib/dns.lua'
ERROR undefined handler for tag `result'
ERROR undefined handler for tag `result'
INFO processing file `nselib/netbios.lua'
ERROR undefined handler for tag `returns'
INFO processing file `nselib/snmp.lua'
ERROR undefined handler for tag `result'
INFO processing file `scripts/SSLv2-support.nse'
ERROR undefined handler for tag `ouput'
Removed a @see tag which refers to Lua's string.format rather than to NSE docs:
INFO generating file `docs/modules/stdnse.html'
ERROR unresolved reference to symbol `string.format'