1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-18 05:29:02 +00:00

Do not treat HTTP 400 as login success. Closes #1942

This commit is contained in:
nnposter
2020-03-04 20:58:49 +00:00
parent 97a891b3e9
commit 4097f39090

View File

@@ -73,6 +73,7 @@ local function try_http_basic_login(host, port, path, user, pass, digest_auth)
local credentials = {username = user, password = pass, digest = digest_auth}
local resp = http_get_simple(host, port, path, {auth=credentials})
return resp.status
and resp.status ~= 400
and resp.status ~= 401
and resp.status ~= 403
and resp.status ~= 404