You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tailscale/util
Nick Khyl 892f8a9582 various: allow tailscaled shutdown via LocalAPI
A customer wants to allow their employees to restart tailscaled at will, when access rights and MDM policy allow it,
as a way to fully reset client state and re-create the tunnel in case of connectivity issues.

On Windows, the main tailscaled process runs as a child of a service process. The service restarts the child
when it exits (or crashes) until the service itself is stopped. Regular (non-admin) users can't stop the service,
and allowing them to do so isn't ideal, especially in managed or multi-user environments.

In this PR, we add a LocalAPI endpoint that instructs ipnserver.Server, and by extension the tailscaled process,
to shut down. The service then restarts the child tailscaled. Shutting down tailscaled requires LocalAPI write access
and an enabled policy setting.

Updates tailscale/corp#32674
Updates tailscale/corp#32675

Signed-off-by: Nick Khyl <nickk@tailscale.com>
4 months ago
..
cache
cibuild
clientmetric util/clientmetric: use counter in aggcounter 12 months ago
cloudenv
cmpver
codegen cmd/viewer, types/views: implement support for json/v2 (#16852) 5 months ago
cstruct
ctxkey
deephash util/deephash: move tests that depend on other tailscale packages to deephash_test 8 months ago
dirwalk
dnsname tailcfg: adjust ServiceName.Validate to use vizerror 12 months ago
eventbus util/eventbus: flesh out docs a bit 4 months ago
execqueue
expvarx util/expvarx: deflake TestSafeFuncHappyPath with synctest 4 months ago
goroutines
groupmember
hashx
httphdr
httpm
limiter
lineiter
lineread
linuxfw all: detect JetKVM and specialize a handful of things for it 6 months ago
lru
mak util/mak: delete long-deprecated, unused, pre-generics NonNil func 9 months ago
multierr
must util/must: add Get2 for functions that return two values 7 months ago
nocasemaps
osdiag
osshare
osuser ssh/tailssh: add Plan 9 support for Tailscale SSH 10 months ago
pidowner
pool
precompress
progresstracking
prompt util/prompt: make yes/no prompt reusable 7 months ago
quarantine
race
racebuild
rands
reload
ringlog util/ringbuffer: rename to ringlog 5 months ago
set util/set: add more functionality to IntSet (#16640) 6 months ago
singleflight
slicesx util/slicesx: add AppendNonzero 12 months ago
stringsx
syspolicy various: allow tailscaled shutdown via LocalAPI 4 months ago
sysresources
systemd util/systemd: don't link systemd-notification package on Android 8 months ago
testenv nettest, *: add option to run HTTP tests with in-memory network 9 months ago
topk
truncate
usermetric wgengine/filter: add check for unknown proto 12 months ago
vizerror
winutil cmd/tailscaled,util/syspolicy/source,util/winutil/gp: disallow acquiring the GP lock during service startup 12 months ago
zstdframe