
Nmap Development mailing list archives
Re: Huawei/H3C Local User enumeration script
From: Kurt Grutzmacher <grutz () jingojango net>
Date: Thu, 25 Oct 2012 14:33:01 -0700
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On October 23, 2012 11:43 AM, David Fifield wrote:
Is there likely to be a default community string? Or is ti not something worth checking for?
That depends upon the device. Most I've come into require the user to define snmp-community with a string while some come configured with "public" as the default which is already used by the NSE SNMP library.
From nselib/snmp.lua:
- -- @args snmpcommunity The community string to use. If not given, it is - -- <code>"public"</code>, or whatever is passed to <code>buildPacket</code>.
You don't make columns in the structured output. Structured output is a
table of name-value pairs. If you need columns, then you additionally return a string with the formatted columns--but we are trying to discourage this kind of output when simple structured output is enough.
output.users[#output.users + 1] = string.format("%s - %s - level: %s",
v.value, password, level)
This is exactly what structured output shouldn't return :)
Ok, other than the string output not coming out in the correct order without sending a separate output_str, this looks much better. It also answers some questions I've had with trying to parse the NSE data in XML output (missing key values for scripts). Is there a plan to update all the scripts that currently are not doing this keyed value output correctly? Thanks for the help. I feel enlightened! New version attached with better text formatting and structured output. - -- - - grutz; -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQIcBAEBAgAGBQJQibAJAAoJEMtvcfrnZQTfMskP/RVWMbJsUZ9U9IS1j+07id9x Yb9oow1A8WNhpv381cBLvKHzlGQfPMkCz+OS6fDt/sOPONYreWW/LmK8YwZGC0OV lmFY/+nepSGB0oAAhQWbg/0Av9jxC9JPOi10D3lXCxsIDC93q44p/fH2zjCafewN DJB73fKmLZyM9HQSUU1XEp/msEz1M8/L50n1V1JbpWVH4UatSQ4KWXIwFjIlsj+j pfM2hZrbODz5CvAVmzmn1AtuULBEKY4hhIsD7uq6rPgMuxum+Mr5KSlg4fsh8jkY YiQ40M2wJengCbEIzNq1qd0LTPtZPIzz3//5lPHHV/RuzMKWBQw0MyuhzRJH+A3R d33tkCv6vQijnYGOGR0XiIkyXavUQrha3CwURuGTYHBUHNU5VFLWbEnTC6mAL8fe XaaNA5HDLmt+s0dHetP5vKjCAjAAxjeylKD6KkIuNjwaYx9pzFBYGvNMv9p6434a WgPVMSfFrg7xHpSAA5YuvuEE87vh87cOz4ZstpAbnn7q4g6v5M6ptJI+fJmgq3d3 9nJSQZOQVVDk87rzncRyaE4GYqzMt9LgxGVlLDvxxPNheAjYbH0Ic10jMAhqimOf eeXEHkeE+fR7CdCcaH0TERCmfhGy3QxE0h0ImqRREi/7ZvTrHDlj03Y0fKDrcCDM Q2PG7XpLJ1jp2sEngdcM =aWf4 -----END PGP SIGNATURE-----
Attachment:
snmp-hh3c-logins.nse
Description:
_______________________________________________ Sent through the nmap-dev mailing list http://cgi.insecure.org/mailman/listinfo/nmap-dev Archived at http://seclists.org/nmap-dev/
Current thread:
- Huawei/H3C Local User enumeration script Kurt Grutzmacher (Oct 23)
- Re: Huawei/H3C Local User enumeration script David Fifield (Oct 24)
- Re: Huawei/H3C Local User enumeration script Kurt Grutzmacher (Oct 25)
- Re: Huawei/H3C Local User enumeration script David Fifield (Oct 25)
- Re: Huawei/H3C Local User enumeration script Kurt Grutzmacher (Oct 25)
- Re: Huawei/H3C Local User enumeration script David Fifield (Nov 07)
- Re: Huawei/H3C Local User enumeration script Kurt Grutzmacher (Oct 25)
- Re: Huawei/H3C Local User enumeration script David Fifield (Oct 24)