Nmap Development mailing list archives
Re: Sergey. [Status report 12/17]
From: Sergey Khegay <g.sergeykhegay () gmail com>
Date: Fri, 22 Jul 2016 17:53:04 -0400
Patrick, I have tried what you suggested, using LUA_USE_APICHECK. The error I get is indeed in a wrong C API call, because execution fails on assertion: Assertion failed: ((L->status == 0) && "cannot do calls on non-normal thread"), function lua_pcallk, file lapi.c, line 956. I though it was because nse_libssh2.cc implementation, as I reported to Fotis, but seems like the bug in the current NSE implementation. I cloned the source code from Nmap's github and just set -DLUA_USE_APICHECK in the liblua/Makefile. (I also used --with-liblua=included for configure script). Then I ran ./nmap -nd 192.168.1.2 --script ftp-brute and it failed on the assertion above.
Starting Nmap 7.25SVN ( https://nmap.org ) at 2016-07-22 17:44 EDT PORTS: Using top 1000 ports found open (TCP:1000, UDP:0, SCTP:0) --------------- Timing report --------------- hostgroups: min 1, max 100000 rtt-timeouts: init 1000, min 100, max 10000 max-scan-delay: TCP 1000, UDP 1000, SCTP 1000 parallelism: min 0, max 0 max-retries: 10, host-timeout: 0 min-rate: 0, max-rate: 0 --------------------------------------------- NSE: Using Lua 5.3. NSE: Arguments from CLI: NSE: Loaded 1 scripts for scanning. NSE: Script Pre-scanning. NSE: Starting runlevel 1 (of 1) scan. Initiating NSE at 17:44 Completed NSE at 17:44, 0.00s elapsed Initiating Ping Scan at 17:44 Scanning 192.168.1.2 [2 ports] Completed Ping Scan at 17:44, 0.00s elapsed (1 total hosts) Overall sending rates: 1119.82 packets / s. Initiating Connect Scan at 17:44 Scanning 192.168.1.2 [1000 ports] Discovered open port 22/tcp on 192.168.1.2 Discovered open port 21/tcp on 192.168.1.2 Discovered open port 111/tcp on 192.168.1.2 Completed Connect Scan at 17:44, 0.10s elapsed (1000 total ports) Overall sending rates: 10589.18 packets / s. NSE: Script scanning 192.168.1.2. NSE: Starting runlevel 1 (of 1) scan. Initiating NSE at 17:44 NSE: Starting ftp-brute against 192.168.1.2:21. Assertion failed: ((L->status == 0) && "cannot do calls on non-normal thread"), function lua_pcallk, file lapi.c, line 956. [1] 77911 abort ./nmap -nd 192.168.1.2 --script ftp-brute
Do you have any ideas what might be wrong? Where should I concentrate now? Apparently I cannot debug nse_libssh2.c before this bug is fixed. Should I check if this bug was present before transition to Lua 5.2?
_______________________________________________ Sent through the dev mailing list https://nmap.org/mailman/listinfo/dev Archived at http://seclists.org/nmap-dev/
Current thread:
- Sergey. [Status report 12/17] Sergey Khegay (Jul 19)
- Re: Sergey. [Status report 12/17] Patrick Donnelly (Jul 19)
- Re: Sergey. [Status report 12/17] Sergey Khegay (Jul 19)
- Re: Sergey. [Status report 12/17] Sergey Khegay (Jul 22)
- Re: Sergey. [Status report 12/17] Patrick Donnelly (Jul 22)
- Re: Sergey. [Status report 12/17] Sergey Khegay (Jul 23)
- Re: Sergey. [Status report 12/17] Sergey Khegay (Jul 19)
- Re: Sergey. [Status report 12/17] Patrick Donnelly (Jul 19)