Update
This commit is contained in:
1 parent
3530afb854
commit
6903fcff27
2146 files changed
+112256
-190703
No files matched your search
+22
-1
@@ -1,9 +1,10 @@
|
||||
// Copyright (c) Tailscale Inc & AUTHORS
|
||||
// Copyright (c) Tailscale Inc & contributors
|
||||
// SPDX-License-Identifier: BSD-3-Clause
|
||||
|
||||
package feature
|
||||
|
||||
import (
|
||||
"io"
|
||||
"net/http"
|
||||
"net/url"
|
||||
"os"
|
||||
@@ -13,6 +14,21 @@ import (
|
||||
"tailscale.com/types/persist"
|
||||
)
|
||||
|
||||
// HookRegisterLogSinkFlags is a hook for the syslog feature to register
|
||||
// its flags (such as tailscaled's --syslog) with the process's default
|
||||
// flag set. If set, tailscaled calls it before flag parsing.
|
||||
var HookRegisterLogSinkFlags Hook[func()]
|
||||
|
||||
// HookLogSink is a hook for the syslog feature to redirect the process's
|
||||
// logs to an alternate sink. If set, tailscaled calls it once early in
|
||||
// main, after flag parsing; on that first call, if the user requested an
|
||||
// alternate sink, it points the standard library's default logger at that
|
||||
// sink. It returns the sink, or nil if logs are not being redirected.
|
||||
// Later callers (such as logpolicy, which otherwise writes its console
|
||||
// copy of logs to stderr) use the returned writer to send their logs to
|
||||
// the same place.
|
||||
var HookLogSink Hook[func() io.Writer]
|
||||
|
||||
// HookCanAutoUpdate is a hook for the clientupdate package
|
||||
// to conditionally initialize.
|
||||
var HookCanAutoUpdate Hook[func() bool]
|
||||
@@ -67,6 +83,11 @@ func TPMAvailable() bool {
|
||||
return false
|
||||
}
|
||||
|
||||
// HookGetSSHHostKeyPublicStrings is a hook for the ssh/hostkeys package to
|
||||
// provide SSH host key public strings to ipn/ipnlocal without ipnlocal needing
|
||||
// to import golang.org/x/crypto/ssh.
|
||||
var HookGetSSHHostKeyPublicStrings Hook[func(varRoot string, logf logger.Logf) ([]string, error)]
|
||||
|
||||
// HookHardwareAttestationAvailable is a hook that reports whether hardware
|
||||
// attestation is supported and available.
|
||||
var HookHardwareAttestationAvailable Hook[func() bool]
|
||||
|
||||
Reference in new issue
Block a user