tailscale/wgengine/router
Nick Khyl 1608831c33 wgengine/router: use quad-100 as the nexthop on Windows
Windows requires routes to have a nexthop. Routes created using the interface's local IP address or an unspecified IP address ("0.0.0.0" or "::") as the nexthop are considered on-link routes. Notably, Windows treats on-link subnet routes differently, reserving the last IP in the range as the broadcast IP and therefore prohibiting TCP connections to it, resulting in WSA error 10049: "The requested address is not valid in its context. This does not happen with single-host routes, such as routes to Tailscale IP addresses, but becomes a problem with advertised subnets when all IPs in the range should be reachable.

Before Windows 8, only routes created with an unspecified IP address were considered on-link, so our previous approach of using the interface's own IP as the nexthop likely worked on Windows 7.

This PR updates configureInterface to use the TailscaleServiceIP (100.100.100.100) and its IPv6 counterpart as the nexthop for subnet routes.

Fixes tailscale/support-escalations#57

Signed-off-by: Nick Khyl <nickk@tailscale.com>
2024-07-18 10:08:29 -05:00
..
callback.go wgengine/router: implement UpdateMagicsockPort for CallbackRouter (#10494) 2023-12-07 10:45:14 -05:00
consolidating_router_test.go wgengine/router: consolidate routes before reconfiguring router for mobile clients 2024-04-23 20:15:56 -05:00
consolidating_router.go wgengine/router: consolidate routes before reconfiguring router for mobile clients 2024-04-23 20:15:56 -05:00
ifconfig_windows_test.go all: use Go 1.22 range-over-int 2024-04-16 15:32:38 -07:00
ifconfig_windows.go wgengine/router: use quad-100 as the nexthop on Windows 2024-07-18 10:08:29 -05:00
router_darwin.go health, all: remove health.Global, finish plumbing health.Tracker 2024-04-26 12:03:11 -07:00
router_default.go health, all: remove health.Global, finish plumbing health.Tracker 2024-04-26 12:03:11 -07:00
router_fake.go util/linuxfw, wgengine: allow ingress to magicsock UDP port on Linux (#10370) 2023-12-05 18:12:02 -05:00
router_freebsd.go health, all: remove health.Global, finish plumbing health.Tracker 2024-04-26 12:03:11 -07:00
router_linux_test.go wgengine/router: print Docker warning when stateful filtering is enabled 2024-05-09 12:26:11 -06:00
router_linux.go health: begin work to use structured health warnings instead of strings, pipe changes into ipn.Notify (#12406) 2024-06-14 11:53:56 -07:00
router_openbsd.go health, all: remove health.Global, finish plumbing health.Tracker 2024-04-26 12:03:11 -07:00
router_test.go various: implement stateful firewalling on Linux (#12025) 2024-05-06 16:22:17 -06:00
router_userspace_bsd.go health, all: remove health.Global, finish plumbing health.Tracker 2024-04-26 12:03:11 -07:00
router_windows_test.go wgengine/router: look up absolute path to netsh.exe on Windows 2024-01-10 20:20:19 -05:00
router_windows.go cmd/tailscaled, net/dns, wgengine/router: start Windows child processes with DETACHED_PROCESS when I/O is being piped 2024-06-11 11:35:26 -06:00
router.go various: implement stateful firewalling on Linux (#12025) 2024-05-06 16:22:17 -06:00
runner.go all: update copyright and license headers 2023-01-27 15:36:29 -08:00