Because of a bug of ResolveUDPAddr, when trying to connect to a dual stacked host (= host with both ipv6 and ipv4 addresses), quic-go client always uses IPv4 instead of prefering IPv6 if available.
net/http (both versions 1.x and 2.0) doesn't behave like that. It prefers IPv6 if available.
As a workaround we're forced to explicitly resolve names before using quic-go http3 client.
demo of the issue: https://github.com/kgersen/h3dial
running on a dual stack machine:
QUIC-GO:
connected to 172.67.9.235:443
got status: 200 OK
proto: HTTP/3.0
net/http:
connected to [2606:4700:10::6816:926]:443
got status: 200 OK
proto: HTTP/2.0
Because of a
bug of ResolveUDPAddr, when trying to connect to a dual stacked host (= host with both ipv6 and ipv4 addresses),quic-goclient always uses IPv4 instead of prefering IPv6 if available.net/http(both versions 1.x and 2.0) doesn't behave like that. It prefers IPv6 if available.As a workaround we're forced to explicitly resolve names before using quic-go http3 client.
demo of the issue: https://github.com/kgersen/h3dial
running on a dual stack machine: