Files
tailscale/net
Brad Fitzpatrick 92ec102673 net/netcheck: mark address family sendable on STUN response
runProbe records IPv4CanSend or IPv6CanSend after SendPacket returns
successfully. A sufficiently fast STUN response can be received and
processed before that return, however, and the report can be cloned in
the intervening window. That produces a contradictory report with UDP
and a valid mapping, but CanSend false. Magicsock treats that as a
send failure and unnecessarily rebinds, perturbing tailcat tests.

A received STUN response itself proves that its address family sent
successfully, so also mark the family sendable while recording the
response.

Before this, the tailcat test flaked after ~3700 runs under
flakestress. Now it can run 30 minutes (12,203 successful runs).

Updates tailscale/tailcat#73

Change-Id: I54fe2e81fc703fac36f693e9dbf0c3fa27d119b1
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
2026-09-03 10:15:01 -07:00
..
2026-07-10 17:39:16 -07:00