mirror of
https://github.com/nmap/nmap.git
synced 2026-01-01 20:39:02 +00:00
Change some http scripts to use host table instead of IP in requests
This commit is contained in:
@@ -66,7 +66,7 @@ untrusted website and XSS injection.]],
|
||||
|
||||
local vuln_report = vulns.Report:new(SCRIPT_NAME, host, port)
|
||||
local header = { ["Referer"] = '"><script>alert("XSS")</script><"' }
|
||||
local open_session = http.get(host.ip, port, "/"..stdnse.generate_random_string(16), { header = header })
|
||||
local open_session = http.get(host, port, "/"..stdnse.generate_random_string(16), { header = header })
|
||||
if open_session and open_session.status == 404 then
|
||||
stdnse.debug2("got 404-that's good!")
|
||||
if open_session.body:match('"><script>alert%("XSS"%)</script><"') then
|
||||
|
||||
Reference in New Issue
Block a user