Files
tailscale/ipn
evan188199-tech 54a4fecaf4 ipn/ipnlocal: keep IPv4 and IPv6 Service VIPs in extraDNS
nodeBackend rebuilt extraDNS from DNS.ExtraRecords as a
map[string]netip.Addr, so a Service's A and AAAA records under the
same name overwrote each other and only the last one (the AAAA,
i.e. the IPv6 VIP) survived. resolveMagicDNS then returned only the
IPv6 VIP for UserDial dials of the Service name, with no IPv4
fallback, and a tcp4 dial of the name failed outright.

Keep every address per name (map[string][]netip.Addr) and select
among them with the same addrForNetwork helper used for device
names, which prefers IPv4 for unqualified networks and honors
tcp4/tcp6. This makes outbound HTTP proxy, SOCKS5, and 'tailscale
nc' dials of Service names reach the IPv4 VIP in IPv4-only
deployments (e.g. Kubernetes operator ingress ProxyGroups).

Fixes #22261

Signed-off-by: evan188199-tech <[email protected]>
2026-12-01 06:33:57 -08:00
..
2026-11-14 09:50:33 -08:00