mirror of
https://github.com/tailscale/tailscale.git
synced 2024-11-30 05:25:35 +00:00
01286af82b
Currently, we get the "likely home router" gateway IP and then iterate through all IPs for all interfaces trying to match IPs to determine the source IP. However, on many platforms we know what interface the gateway is through, and thus we don't need to iterate through all interfaces checking IPs. Instead, use the IP address of the associated interface. This better handles the case where we have multiple interfaces on a system all connected to the same gateway, and where the first interface that we visit (as iterated by ForeachInterfaceAddress) isn't also the default internet route. Updates #8992 Signed-off-by: Andrew Dunham <andrew@du.nham.ca> Change-Id: I8632f577f1136930f4ec60c76376527a19a47d1f |
||
---|---|---|
.. | ||
interfaces_bsd.go | ||
interfaces_darwin_test.go | ||
interfaces_darwin.go | ||
interfaces_default_route_test.go | ||
interfaces_defaultrouteif_todo.go | ||
interfaces_freebsd.go | ||
interfaces_linux_test.go | ||
interfaces_linux.go | ||
interfaces_test.go | ||
interfaces_windows_test.go | ||
interfaces_windows.go | ||
interfaces.go |