Home page logo
/

nmap-dev logo Nmap Development mailing list archives

Re: [NSE] http library patch
From: David Fifield <david () bamsoftware com>
Date: Sun, 6 Nov 2011 15:00:26 -0800

On Wed, Nov 02, 2011 at 11:07:00AM +0100, Patrik Karlsson wrote:
Hi all,

I've noticed that the scripts collecting information from the Citrix XML
service sometimes fail.
The reason for this is that there's no CRLF after the chunked-data in the
response.
I would therefore like to commit the following patch that changes the
behavior of the library to just print a warning if it detects this error
instead of aborting.

--- nselib/http.lua (revision 26971)
+++ nselib/http.lua (working copy)
@@ -493,7 +493,7 @@

     line, partial = recv_line(s, partial)
     if not line then
-      return nil, string.format("Didn't find CRLF after chunk-data.")
+      stdnse.print_debug(2, "Didn't find CRLF after chunk-data.")
     elseif not string.match(line, "^\r?\n") then
       return nil, string.format("Didn't find CRLF after chunk-data; got
%q.", line)
     end

Before I do commit it, I just wanted to do a quick check whether there's a
reason not to do this?

I think that looks fine. Please add a comment stating that the Citrix
XML service is broken in this way.

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


  By Date           By Thread  

Current thread:
[ Nmap | Sec Tools | Mailing Lists | Site News | About/Contact | Advertising | Privacy ]
AlienVault