Description
Describe the problem
Programs linked against muslc
cannot resolve the peer name against a DNS provided by Netbird client . getaddrinfo
with default addrinfo
returns EAI_NONAME
.
Musl's getaddrinfo
with default settings (specifically addrinfo.af_family == AF_UNSPEC
) asks for both A
and AAAA
entry. If any response contains a flag "No such name", error EAI_NONAME
is returned. This behaviour is different in glibc. Relevant mailing list: https://www.openwall.com/lists/musl/2021/07/19/8
To Reproduce
Steps to reproduce the behavior:
0. Connect to a netbird network.
$ docker run --network host -it alpine
- In a container:
$ ping <valid-peer-domain-name>
- Failure occurs
You can also see that choosing to resolve only IPv4 works
$ ping -4 <valid-peer-name
Expected behavior
Proper peer name resolution. Not sure what Netbird's DNS should do but DNSes for example for github.com
seem to respond with an empty response but a flag is "No error" instead of "No such name"? Not sure.
Thanks a lot.