From 3c8d257b3e61eecf1d5760af5449096f9b7f4e75 Mon Sep 17 00:00:00 2001 From: Denton Gentry Date: Wed, 17 Aug 2022 20:15:57 -0700 Subject: [PATCH] cmd/tailscale: set /dev/net perms in configure-host Several customers have had issues due to the permissions on /dev/net. Set permissions to 0755. Fixes https://github.com/tailscale/tailscale/issues/5048 Signed-off-by: Denton Gentry --- cmd/tailscale/cli/configure-host.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/tailscale/cli/configure-host.go b/cmd/tailscale/cli/configure-host.go index 6a52472c7..db688aeb4 100644 --- a/cmd/tailscale/cli/configure-host.go +++ b/cmd/tailscale/cli/configure-host.go @@ -62,6 +62,9 @@ func runConfigureHost(ctx context.Context, args []string) error { return fmt.Errorf("creating /dev/net/tun: %v, %s", err, out) } } + if err := os.Chmod("/dev/net", 0755); err != nil { + return err + } if err := os.Chmod("/dev/net/tun", 0666); err != nil { return err }