mirror of
https://github.com/nmap/nmap.git
synced 2026-09-21 15:46:45 +00:00
Add TCP support to dns.lua
Slightly modified from patch from John Bond: http://seclists.org/nmap-dev/2014/q1/118
This commit is contained in:
parent
d36c08dcf5
commit
972d799143
3 changed files with 60 additions and 5 deletions
|
|
@ -63,7 +63,7 @@ end
|
|||
action = function(host, port)
|
||||
local result = stdnse.output_table()
|
||||
local flag = false
|
||||
local status, resp = dns.query("id.server", {host = host.ip, dtype='TXT', class=dns.CLASS.CH, retAll=true, retPkt=true, nsid=true, dnssec=true})
|
||||
local status, resp = dns.query("id.server", {host = host.ip, port=port.number, proto=port.protocol, dtype='TXT', class=dns.CLASS.CH, retAll=true, retPkt=true, nsid=true, dnssec=true})
|
||||
if ( status ) then
|
||||
local status, nsid = rr_filter(resp.add,'OPT')
|
||||
if ( status ) then
|
||||
|
|
@ -83,7 +83,7 @@ action = function(host, port)
|
|||
result["id.server"] = id_server
|
||||
end
|
||||
end
|
||||
local status, bind_version = dns.query("version.bind", {host = host.ip, dtype='TXT', class=dns.CLASS.CH})
|
||||
local status, bind_version = dns.query("version.bind", {host = host.ip, port=port.number, proto=port.protocol, dtype='TXT', class=dns.CLASS.CH})
|
||||
if ( status ) then
|
||||
flag = true
|
||||
result["bind.version"] = bind_version
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue