do not use dns.ADDRCONFIG for localhost
authorJérémy Lal <kapouer@melix.org>
Sat, 18 May 2024 12:26:22 +0000 (14:26 +0200)
committerJérémy Lal <kapouer@melix.org>
Sat, 18 May 2024 12:26:22 +0000 (14:26 +0200)
Last-Update: 2020-06-11
Bug-Debian: https://bugs.debian.org/962318
Forwarded: https://github.com/nodejs/node/issues/33816

it fails on IPv6-only systems. Setting it with libc fails on linux.
https://github.com/nodejs/node/issues/33279
https://lists.debian.org/debian-devel/2023/12/msg00011.html

Gbp-Pq: Topic deps
Gbp-Pq: Name localhost-no-addrconfig.patch

lib/net.js
test/sequential/sequential.status

index 4efe7eff6dab697cf498fe67ebbb444a689766ee..812de3e02f68210d3a2943b4a83f97bc2199595c 100644 (file)
@@ -1,4 +1,5 @@
 // Copyright Joyent, Inc. and other Node contributors.
+
 //
 // Permission is hereby granted, free of charge, to any person obtaining a
 // copy of this software and associated documentation files (the
@@ -1338,13 +1339,6 @@ function lookupAndConnect(self, options) {
     hints: options.hints || 0,
   };
 
-  if (!isWindows &&
-      dnsopts.family !== 4 &&
-      dnsopts.family !== 6 &&
-      dnsopts.hints === 0) {
-    dnsopts.hints = dns.ADDRCONFIG;
-  }
-
   debug('connect: find host', host);
   debug('connect: dns options', dnsopts);
   self._host = host;
index b48ac634519ee4428d309475c2cdb3bb929b4e14..7b4db29d373234467789438dbbfec21fea4a72ed 100644 (file)
@@ -35,6 +35,10 @@ test-debugger-heap-profiler: PASS,FLAKY
 test-watch-mode: SKIP
 test-watch-mode-inspect: SKIP
 
+# does not work on IPv6 only host
+test-tls-psk-client: PASS,FLAKY
+test-tls-securepair-client: PASS,FLAKY
+
 [$system==win32]
 # https://github.com/nodejs/node/issues/47116
 test-http-max-sockets: PASS, FLAKY