Nmap Development mailing list archives

ScanProgressMeter::printStats causing occasional segfault


From: Brandon Enright <bmenrigh () ucsd edu>
Date: Fri, 6 Feb 2009 04:51:38 +0000

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Unrelated to my previous gh_list report, the same command, namely:

$ sudo ./nmap --datadir . --script=smb-brute.nse -sC -p 135,139,445 -P S135,139,445 -T5 -v -n -d a.b.0.0/16 c.d.0.0/16 
--min-hostgroup 4096 --min-parallelism 4096 --host-timeout 240m -oA smbbrute_campus 2>&1 > smbbrute_campus.txt 
2>smbbrute_campus.err

is occasionally causing a segfault.  I think this is related to the
changes David and Henri made to try to fix the negative times being
reported on long scans. Here is a backtrace:

Program terminated with signal 11, Segmentation fault.
#0  ScanProgressMeter::printStats (this=0x7fffd7a78410,
    perc_done=0.7119341563786008, now=0x0) at timing.cc:563
563       last_print = *now;
(gdb) bt
#0  ScanProgressMeter::printStats (this=0x7fffd7a78410,
    perc_done=0.7119341563786008, now=0x0) at timing.cc:563
#1  0x0000000000468e7d in process_mainloop (L=0xc59980) at nse_main.cc:467
#2  0x0000000000469bd8 in script_scan (targets=@0x15a9ef0) at nse_main.cc:354
#3  0x000000000041d9e4 in nmap_main (argc=23, argv=0x7fffd7a7e088)
    at nmap.cc:1817
#4  0x0000000000419747 in main (argc=23, argv=0x7fffd7a7e088) at main.cc:224


now happens to be null so that pointer dereference isn't too happy.

(gdb) print now
$1 = (const timeval *) 0x0

Let me know if there is any additional information I can provide.

Brandon

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.9 (GNU/Linux)

iEYEARECAAYFAkmLwdoACgkQqaGPzAsl94IT0QCfXHYhPym1Alaa4g5wRV6pUP3w
7yAAoJS8wNVU5GK9LNOClvDUAWt13rJ9
=hIh4
-----END PGP SIGNATURE-----

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


Current thread: