From 7ad4989e12173bca56dd652ee0ce5ccca1434de9 Mon Sep 17 00:00:00 2001 From: Ben Noordhuis Date: Wed, 29 Jan 2020 13:12:15 +0100 Subject: [PATCH 1/2] dns: default to verbatim=true in dns.lookup() Switch the default from false (reorder the result so that IPv4 addresses come before IPv6 addresses) to true (return them exactly as the resolver sent them to us.) Fixes: https://github.com/nodejs/node/issues/31566 Refs: https://github.com/nodejs/node/issues/6307 Refs: https://github.com/nodejs/node/pull/20710 --- doc/api/dns.md | 7 ++++--- lib/dns.js | 4 ++-- lib/internal/dns/promises.js | 4 ++-- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/doc/api/dns.md b/doc/api/dns.md index 6c7f29cfaf0f85..c1ebb11a7d8565 100644 --- a/doc/api/dns.md +++ b/doc/api/dns.md @@ -124,6 +124,9 @@ section if a custom port is used.