Nmap Development mailing list archives

Re: Problem saving pages with http-headers.nse script


From: David Fifield <david () bamsoftware com>
Date: Fri, 25 Jan 2013 09:38:11 -0800

On Thu, Jan 24, 2013 at 02:49:36PM -0800, al bell wrote:
I am running nmap 6.25 in the following way:

c:\test\scanned_files>nmap -p 80 10.10.6.74 --script http-headers
--script-args useget=/  -oX c:\test\scanned_files\74.xml

The output does not include the html for / , as expected.

When I run nmap with --script-trace, I can see the html on the screen, but
it is not saved as psart of the xml output. I would expect the HTML to be
saved on the script_output tag.

Any help will be greatly appreciated.

It seems to work for me. The script output is a child of the <port>
element in this case; you might have been looking for it somewhere else.

$ nmap -p 80 --script=http-headers --script-args useget=1 scanme.nmap.org -oX -
...
<port protocol="tcp" portid="80">
  <state state="open" reason="syn-ack" reason_ttl="0"/>
  <service name="http" method="table" conf="3"/>
  <script id="http-headers"
          output="&#xa;  Date: Fri, 25 Jan 2013 17:35:58 GMT&#xa;  Server: Apache/2.2.14 (Ubuntu)&#xa;  Accept-Ranges: 
bytes&#xa;  Vary: Accept-Encoding&#xa;  Connection: close&#xa;  Transfer-Encoding: chunked&#xa;  Content-Type: 
text/html&#xa;  &#xa;  (Request type: GET)&#xa;"/>
</port>
...

David Fifield
_______________________________________________
Sent through the dev mailing list
http://nmap.org/mailman/listinfo/dev
Archived at http://seclists.org/nmap-dev/


Current thread: