From a7ca9aba7bc31c5071d39191aa96b9d6740769a8 Mon Sep 17 00:00:00 2001 From: dmiller Date: Fri, 9 May 2025 22:47:07 +0000 Subject: [PATCH] Also try system resolver for unqualified (no-dot) DNS names --- nmap_dns.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/nmap_dns.cc b/nmap_dns.cc index 3b63e783c..e3021d0bf 100644 --- a/nmap_dns.cc +++ b/nmap_dns.cc @@ -802,6 +802,11 @@ static void read_evt_handler(nsock_pool nsp, nsock_event evt, void *) { break; } } + if (!processing_successful && reqt->name.find('.') == std::string::npos) { + // Names without a dot: system resolver may do better. + process_request(ACTION_SYSTEM_RESOLVE, reqinfo); + processing_successful = true; + } } if (!processing_successful) {