Nmap Development mailing list archives
Re: hddtemp-info.nse
From: Toni Ruottu <toni.ruottu () iki fi>
Date: Tue, 30 Nov 2010 19:03:35 +0200
The problem seems to be that comm always does a single receive. If the network conditions are good this does not matter, but over the Internet the first receive is not likely to contain the full banner. I think the comm library needs to be changed to do as many receives as it is able to do before a time out. --Toni On Mon, Nov 29, 2010 at 9:02 PM, David Fifield <david () bamsoftware com> wrote:
On Mon, Nov 29, 2010 at 04:30:01PM +0200, Toni Ruottu wrote:hello I just finished writing an nse script that gets hard disk information from hddtemp service. See the attachment. To try the script out you could install hddtemp on an Ubuntu system by commanding: sudo apt-get install hddtemp The installation asks whether or not you want to run the service automatically. By default it runs on localhost only so auto-starting it should be relatively safe. After installing hddtemp you may run the script by saying: nmap --script=hddtemp-info.nse -p 7634 127.0.0.1Thanks for writing such a short and understandable script. I have already added it. At first I thought this would be better handled with service detection, but that wouldn't work with more than one hard drive. My hard drive doesn't appear to have a temperature sensor (or hddtemp doesn't support it) so I get different output: $ ncat localhost 7634 |/dev/sda|Hitachi HTS725025A9A364|UNK|*| $ ./nmap --script=hddtemp-info localhost -p 7634 PORT STATE SERVICE 7634/tcp open hddtemp | hddtemp-info: |_ /dev/sda: Hitachi HTS725025A9A364: UNK * $ sudo hddtemp /dev/sda WARNING: Drive /dev/sda doesn't seem to have a temperature sensor. WARNING: This doesn't mean it hasn't got one. WARNING: If you are sure it has one, please contact me (hddtemp () guzu net). WARNING: See --help, --debug and --drivebase options. /dev/sda: Hitachi HTS725025A9A364: no sensorFor some reason the script seems to work every time for localhost, most of the time within a LAN, but only sometimes over the Internet. I am suspecting this to be a bug/feature in comm.get_banner, as I do not do anything special that might cause the error. Using ncat I am able to get the same information every time, even over the Internet. Any suggestions of what might cause the problem?Run with --script-trace to see what's happening. 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:
- hddtemp-info.nse Toni Ruottu (Nov 29)
- Re: hddtemp-info.nse David Fifield (Nov 29)
- Re: hddtemp-info.nse Toni Ruottu (Nov 30)
- Re: hddtemp-info.nse David Fifield (Dec 08)
- Re: hddtemp-info.nse Toni Ruottu (Dec 09)
- Re: hddtemp-info.nse David Fifield (Dec 11)
- Re: hddtemp-info.nse Toni Ruottu (Dec 12)
- Re: hddtemp-info.nse David Fifield (Dec 12)
- Re: hddtemp-info.nse Toni Ruottu (Dec 13)
- Re: hddtemp-info.nse Toni Ruottu (Dec 30)
- Re: hddtemp-info.nse Toni Ruottu (Nov 30)
- Re: hddtemp-info.nse David Fifield (Nov 29)