net/netutil: add CheckIPForwardingLinux (#4301)

Combine the code between `LocalBackend.CheckIPForwarding` and
`controlclient.ipForwardingBroken`.

Fixes #4300

Signed-off-by: Maisem Ali <maisem@tailscale.com>
This commit is contained in:
Maisem Ali
2022-03-28 10:24:11 -07:00
committed by GitHub
parent 7c7f37342f
commit 309ddef852
4 changed files with 238 additions and 175 deletions

View File

@@ -238,3 +238,6 @@ func AllIPv4() netaddr.IPPrefix { return allIPv4 }
// AllIPv6 returns ::/0.
func AllIPv6() netaddr.IPPrefix { return allIPv6 }
// ExitRoutes returns a slice containing AllIPv4 and AllIPv6.
func ExitRoutes() []netaddr.IPPrefix { return []netaddr.IPPrefix{allIPv4, allIPv6} }