tailscale/wgengine/router
David Anderson 68ddf134d7 wgengine/router/dns: issue ipconfig /registerdns when applying DNS settings.
Amazingly, there doesn't seem to be a documented way of updating network
configuration programmatically in a way that Windows takes notice of.
The naturopathic remedy for this is to invoke ipconfig /registerdns, which
does a variety of harmless things and also invokes the private API that
tells windows to notice new adapter settings. This makes our DNS config
changes stick within a few seconds of us setting them.

If we're invoking a shell command anyway, why futz with the registry at
all? Because netsh has no command for changing the DNS suffix list, and
its commands for setting resolvers requires parsing its output and
keeping track of which server is in what index. Amazingly, twiddling
the registry directly is the less painful option.

Fixes #853.

Signed-off-by: David Anderson <danderson@tailscale.com>
2020-10-29 20:05:38 -07:00
..
dns wgengine/router/dns: issue ipconfig /registerdns when applying DNS settings. 2020-10-29 20:05:38 -07:00
ifconfig_windows_test.go wgengine/router: unfork winipcfg-go package, use upstream 2020-10-13 09:21:22 -07:00
ifconfig_windows.go wgengine/router: fix bug where getInterfaceRoutes always returned an empty list 2020-10-29 14:38:59 -07:00
router_darwin.go all: dns refactor, add Proxied and PerDomain flags from control (#615) 2020-07-31 16:27:09 -04:00
router_default.go Remove tuntap references. We only use TUN. 2020-09-25 13:13:13 -07:00
router_fake.go wgengine/router: rename config.Settings to config.Config, make pointer. 2020-05-12 15:58:33 -07:00
router_freebsd.go all: dns refactor, add Proxied and PerDomain flags from control (#615) 2020-07-31 16:27:09 -04:00
router_linux_test.go wgengine/router: make v6-ness configurable in test, for consistent results. 2020-09-28 23:47:05 +00:00
router_linux.go wgengine/router: fix configuration of loopback netfilter rules for v6. 2020-10-15 15:15:24 -07:00
router_openbsd.go wgengine/router: remove unnecessary newlines in log.Printf formats 2020-09-01 13:27:42 -07:00
router_userspace_bsd.go wgengine/router: remove unnecessary newlines in log.Printf formats 2020-09-01 13:27:42 -07:00
router_windows.go wgengine/router: make Windows firewall configuration async 2020-10-29 13:40:20 -07:00
router.go all: dns refactor, add Proxied and PerDomain flags from control (#615) 2020-07-31 16:27:09 -04:00
runner.go wgengine/router: set up basic IPv6 routing/firewalling. 2020-09-24 18:37:00 -07:00