1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-24 16:39:03 +00:00

Added a check at the start for a password-protected root folder. Prevents checking if we can't get useful results.

This commit is contained in:
ron
2009-05-19 21:27:05 +00:00
parent 571145d92a
commit 51b9dd426b

View File

@@ -89,7 +89,6 @@ local function go(host, port)
local results = {}
local is_vulnerable = true
local folder_file
if(nmap.registry.args.folderdb ~= nil) then
folder_file = nmap.fetchfile(nmap.registry.args.folderdb)
@@ -134,6 +133,12 @@ local function go(host, port)
end
action = function(host, port)
-- Start by checking if '/' is protected -- if it is, we can't do the tests
local result = go_single(host, port, "/")
if(result == enum_results.NOT_VULNERABLE) then
return "Could not determine vulnerability, since root folder is password protected"
end
if(nmap.registry.args.webdavfolder ~= nil) then
local folder = nmap.registry.args.webdavfolder
local result = go_single(host, port, "/" .. folder)