You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tailscale/net
Josh Bleecher Snyder ad5e04249b wgengine/monitor: ignore adding/removing uninteresting IPs
One of the most common "unexpected" log lines is:

"network state changed, but stringification didn't"

One way that this can occur is if an interesting interface
(non-Tailscale, has interesting IP address)
gains or loses an uninteresting IP address (link local or loopback).

The fact that the interface is interesting is enough for EqualFiltered
to inspect it. The fact that an IP address changed is enough for
EqualFiltered to declare that the interfaces are not equal.

But the State.String method reasonably declines to print any
uninteresting IP addresses. As a result, the network state appears
to have changed, but the stringification did not.

The String method is correct; nothing interesting happened.

This change fixes this by adding an IP address filter to EqualFiltered
in addition to the interface filter. This lets the network monitor
ignore the addition/removal of uninteresting IP addresses.

Signed-off-by: Josh Bleecher Snyder <josh@tailscale.com>
4 years ago
..
dns net/dns: make constants for the various DBus strings. 4 years ago
dnscache net/{dnscache,interfaces}: use netaddr.IP.IsPrivate, delete copied code 4 years ago
dnsfallback net/netns: thread logf into control functions 4 years ago
flowtrack all: use testingutil.MinAllocsPerRun 4 years ago
interfaces wgengine/monitor: ignore adding/removing uninteresting IPs 4 years ago
netcheck net/netns: thread logf into control functions 4 years ago
netknob all: disable TCP keep-alives on iOS/Android 4 years ago
netns net/netns: thread logf into control functions 4 years ago
netstat all: gofmt with Go 1.17 4 years ago
nettest net/nettest: make nettest.NewConn pass x/net/nettest.TestConn. 5 years ago
packet all: use testingutil.MinAllocsPerRun 4 years ago
portmapper net/portmapper: mark fewer PMP probe failures as unexpected 4 years ago
socks5 net/socks5/tssocks: add a SOCKS5 dialer type, method-ifying code 5 years ago
speedtest all: fix spelling mistakes 4 years ago
stun all: gofmt with Go 1.17 4 years ago
tlsdial net/tlsdial: add forgotten test file for go mod tidy 4 years ago
tsaddr ipn/ipnlocal: for IPv6-only nodes, publish IPv6 MagicDNS records of peers 4 years ago
tshttpproxy net/tshttpproxy: use correct size for Windows BOOL argument 4 years ago
tstun net/tstun, wgengine: add packet-level and drop metrics 4 years ago