1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-06 04:31:29 +00:00

Fix a bug: if service is vulnerable, this is a table, not a string.

This commit is contained in:
dmiller
2018-10-25 16:30:48 +00:00
parent e3d08f7e94
commit 1c2829cbd0

View File

@@ -137,7 +137,7 @@ action = function(host, port)
local test_status, test_result = msrpc.svcctl_openservicew(smbstate, open_result['handle'], test_service, 0x00000)
-- If the service DOES_NOT_EXIST, we couldn't run code
if string.match(test_result, 'DOES_NOT_EXIST') then
if not test_status and string.match(test_result, 'DOES_NOT_EXIST') then
stdnse.debug1("Result: Test service does not exist: probably not vulnerable")
msrpc.svcctl_closeservicehandle(smbstate, open_result['handle'])