Closed hoilc closed 4 years ago
got v11 introduced DNS cache as a default behavior by using cacheable-lookup.
got
cacheable-lookup
Unexpectedly, it breaks http request in some IPv6-only environment where the DNS server support both IPv4 and IPv6.
By default, cacheable-lookup return IPv4 addresses which are unreachable from the server.
With the commonly used library glibc (http://man7.org/linux/man-pages/man3/getaddrinfo.3.html#NOTES), I expect IPv6 addresses without extra configurations in the same situation.
glibc
In other words, the following test is expected to be passed.
{ const CacheableLookup = mockedInterfaces({has4: false, has6: true}); const cacheable = new CacheableLookup({resolver, customHostsPath: false}); verify(t, await cacheable.lookupAsync('localhost'), { address: '::ffff:127.0.0.2', family: 6 }); }
Fixed in b2348d5aede36bdf625eba2aa17ca4dedb74c62b
got
v11 introduced DNS cache as a default behavior by usingcacheable-lookup
.Unexpectedly, it breaks http request in some IPv6-only environment where the DNS server support both IPv4 and IPv6.
By default,
cacheable-lookup
return IPv4 addresses which are unreachable from the server.With the commonly used library
glibc
(http://man7.org/linux/man-pages/man3/getaddrinfo.3.html#NOTES), I expect IPv6 addresses without extra configurations in the same situation.In other words, the following test is expected to be passed.