Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--dns-result-order=ipv4first behaviour change in v22.12.0 #56204

Closed
DevRCRun opened this issue Dec 10, 2024 · 4 comments
Closed

--dns-result-order=ipv4first behaviour change in v22.12.0 #56204

DevRCRun opened this issue Dec 10, 2024 · 4 comments
Labels
confirmed-bug Issues with confirmed bugs. dns Issues and PRs related to the dns subsystem. windows Issues and PRs related to the Windows platform.

Comments

@DevRCRun
Copy link

Version

v22.12.0

Platform

Microsoft Windows NT 10.0.20348.0 x64

Subsystem

dns

What steps will reproduce the bug?

We are tracking v22.x with a view to migrating in the Spring. Have just upgraded test system from v22.11.0 and restarted applications.

Applications are express configured to listen on https with server hostname. Under Node 18.x we are using --dns-result-order=ipv4first to get the binding to the IPV4 address rather than IPV6. This worked the same with v22.11.0

Now that v22.12.0 is installed in place of v22.11.0 - despite the argument still being in place, the application binds to the IPV6 address.

With the argument removed, the IPV6 address binds also.

How often does it reproduce? Is there a required condition?

As above

What is the expected behavior? Why is that the expected behavior?

Node binds to IPV4 address.

What do you see instead?

Node binds to IPV6 address

Additional information

In https://nodejs.org/en/blog/release/v22.12.0 I can see #55392

Using the same test as the original reporter, under Node 18.x I get

null [ { address: '::1', family: 6 }, { address: '127.0.0.1', family: 4 } ]

Under 22.11.0 it is the same

null [ { address: '::1', family: 6 }, { address: '127.0.0.1', family: 4 } ]

But with 22.12.0 installed it outputs

null [ { address: '::1', family: 6 } ]

Thanks

@targos targos added confirmed-bug Issues with confirmed bugs. dns Issues and PRs related to the dns subsystem. labels Dec 10, 2024
@targos
Copy link
Member

targos commented Dec 10, 2024

I can reproduce, but I'm not sure #55392 is the cause (it's not an order problem):

> volta run --node 20 node -e "void dns.lookup('localhost', {all:true}, console.log)"
null [ { address: '::1', family: 6 }, { address: '127.0.0.1', family: 4 } ]
> volta run --node 22.11.0 node -e "void dns.lookup('localhost', {all:true}, console.log)"
null [ { address: '::1', family: 6 }, { address: '127.0.0.1', family: 4 } ]
> volta run --node 22.12.0 node -e "void dns.lookup('localhost', {all:true}, console.log)"
null [ { address: '::1', family: 6 } ]
> volta run --node 23 node -e "void dns.lookup('localhost', {all:true}, console.log)"
null [ { address: '::1', family: 6 } ]

@targos
Copy link
Member

targos commented Dec 10, 2024

@nodejs/dns

The other DNS-related change in v22.12.0 was #55430

@lpinca
Copy link
Member

lpinca commented Dec 10, 2024

Duplicate of #56137. I think this is the result of a c-ares update.

@lpinca lpinca added the windows Issues and PRs related to the Windows platform. label Dec 10, 2024
@aduh95
Copy link
Contributor

aduh95 commented Dec 10, 2024

Duplicate of #56137

@aduh95 aduh95 marked this as a duplicate of #56137 Dec 10, 2024
@aduh95 aduh95 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
confirmed-bug Issues with confirmed bugs. dns Issues and PRs related to the dns subsystem. windows Issues and PRs related to the Windows platform.
Projects
None yet
Development

No branches or pull requests

4 participants