Nmap Development mailing list archives

Re: Hang on SNMP script?


From: David Fifield <david () bamsoftware com>
Date: Mon, 24 Sep 2012 22:25:14 -0700

On Tue, Sep 18, 2012 at 03:18:34PM -0700, David Fifield wrote:
I see alternation between a1 and a2 in this column ↑↑
According to snmp.lua, these are "Get Next" and "Get Response". It seems
that the OID is not changing each time, though.

Please try this patch and we can see what OIDs are being tried. An OID
comparison is controlling the exit from the loop in snmpWalk.

David Fifield

diff --git nselib/snmp.lua nselib/snmp.lua
index 2bf4c5f..11573ce 100644
--- nselib/snmp.lua
+++ nselib/snmp.lua
@@ -497,6 +497,7 @@ function snmpWalk( socket, base_oid )
              value = snmpdata[1][1]
              oid  = snmpdata[1][2]
              
+             stdnse.print_debug("base_oid %s oid %s", base_oid, oid)
              if not oid:match( base_oid ) or base_oid == oid then
                      break
              end

Did you have any luck with this patch, Chris?

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

Current thread: