mirror of
https://github.com/tailscale/tailscale.git
synced 2026-06-03 21:01:54 +08:00
bind() on NETLINK_ROUTE sockets does not work on Android 11+ (https://developer.android.com/identity/user-data-ids#mac-11-plus) . Since system/bin/ip uses bind(), likelyHomeRouterIPHelper() always fails on Andoroid 11+, so that GatewayAndSelfIP never caches the result, causing repeated ip process spawns on every periodic ReSTUN. This replaces the system/bin/ip fallback with a cached gateway IP pushed from Android’s ConnectivityManager via LinkProperties.getRoutes(). This is the same patterm used by UpdateLastKnownDefaultRouteInterface for the interface name (see https://github.com/tailscale/tailscale/pull/11784/). We keep the proc/net/route path as a fallback for early startup before NetworkChangeCallback has fired. Updates tailscale/tailscale#18622 Updates tailscale/tailscale#13352 Signed-off-by: kari-ts <kari@tailscale.com> |
||
|---|---|---|
| .. | ||
| defaultroute_bsd.go | ||
| defaultroute_darwin.go | ||
| interfaces_android.go | ||
| interfaces_bsd.go | ||
| interfaces_bsdroute.go | ||
| interfaces_darwin_test.go | ||
| interfaces_darwin.go | ||
| interfaces_default_route_test.go | ||
| interfaces_defaultrouteif_todo.go | ||
| interfaces_linux_test.go | ||
| interfaces_linux.go | ||
| interfaces_test.go | ||
| interfaces_windows_test.go | ||
| interfaces_windows.go | ||
| interfaces.go | ||
| loghelper_test.go | ||
| loghelper.go | ||
| netmon_darwin_test.go | ||
| netmon_darwin.go | ||
| netmon_freebsd.go | ||
| netmon_linux_test.go | ||
| netmon_linux.go | ||
| netmon_polling.go | ||
| netmon_test.go | ||
| netmon_windows.go | ||
| netmon.go | ||
| polling.go | ||
| state.go | ||