mirror of
https://github.com/nmap/nmap.git
synced 2025-12-17 21:19:01 +00:00
Applied patch from Jah:
Attached corrects answerFetcher[types.TXT]() in dns.lua which inserts v.data into answers only if v.domain is present - I believe the test should be for v.data. This was preventing TXT answers from being returned from dns.query() with the retAll option.
This commit is contained in:
@@ -251,7 +251,7 @@ answerFetcher[types.TXT] =
|
|||||||
else
|
else
|
||||||
local answers = {}
|
local answers = {}
|
||||||
for _, v in ipairs(dec.answers) do
|
for _, v in ipairs(dec.answers) do
|
||||||
if v.domain then table.insert(answers, string.sub(v.data, 2)) end
|
if v.data then table.insert(answers, string.sub(v.data, 2)) end
|
||||||
end
|
end
|
||||||
return answers
|
return answers
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user