controlknobs
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Overview¶
Package controlknobs contains client options configurable from control which can be turned onor off. The ability to turn options on and off is for incrementally adding features in.
Index¶
Constants¶
This section is empty.
Variables¶
This section is empty.
Functions¶
This section is empty.
Types¶
typeKnobs¶added inv1.50.0
type Knobs struct {// DisableUPnP indicates whether to attempt UPnP mapping.DisableUPnPatomic.Bool// KeepFullWGConfig is whether we should disable the lazy wireguard// programming and instead give WireGuard the full netmap always, even for// idle peers.KeepFullWGConfigatomic.Bool// RandomizeClientPort is whether control says we should randomize// the client port.RandomizeClientPortatomic.Bool// OneCGNAT is whether the the node should make one big CGNAT route// in the OS rather than one /32 per peer.OneCGNATsyncs.AtomicValue[opt.Bool]// ForceBackgroundSTUN forces netcheck STUN queries to keep// running in magicsock, even when idle.ForceBackgroundSTUNatomic.Bool// DisableDeltaUpdates is whether the node should not process// incremental (delta) netmap updates and should treat all netmap// changes as "full" ones as tailscaled did in 1.48.x and earlier.DisableDeltaUpdatesatomic.Bool// PeerMTUEnable is whether the node should do peer path MTU discovery.PeerMTUEnableatomic.Bool// DisableDNSForwarderTCPRetries is whether the DNS forwarder should// skip retrying truncated queries over TCP.DisableDNSForwarderTCPRetriesatomic.Bool// SilentDisco is whether the node should suppress disco heartbeats to its// peers.SilentDiscoatomic.Bool// LinuxForceIPTables is whether the node should use iptables for Linux// netfiltering, unless overridden by the user.LinuxForceIPTablesatomic.Bool// LinuxForceNfTables is whether the node should use nftables for Linux// netfiltering, unless overridden by the user.LinuxForceNfTablesatomic.Bool// SeamlessKeyRenewal is whether to renew node keys without breaking connections.// This is enabled by default in 1.90 and later, but we but we can remotely disable// it from the control plane if there's a problem.//http://go/seamless-key-renewalSeamlessKeyRenewalatomic.Bool// ProbeUDPLifetime is whether the node should probe UDP path lifetime on// the tail end of an active direct connection in magicsock.ProbeUDPLifetimeatomic.Bool// AppCStoreRoutes is whether the node should store RouteInfo to StateStore// if it's an app connector.AppCStoreRoutesatomic.Bool// UserDialUseRoutes is whether tsdial.Dialer.UserDial should use routes to determine// how to dial the destination address. When true, it also makes the DNS forwarder// use UserDial instead of SystemDial when dialing resolvers.UserDialUseRoutesatomic.Bool// DisableSplitDNSWhenNoCustomResolvers indicates that the node's DNS manager// should not adopt a split DNS configuration even though the Config of the// resolver only contains routes that do not specify custom resolver(s), hence// all DNS queries can be safely sent to the upstream DNS resolver and the// node's DNS forwarder doesn't need to handle all DNS traffic.// This is for now (2024-06-06) an iOS-specific battery life optimization,// and this knob allows us to disable the optimization remotely if needed.DisableSplitDNSWhenNoCustomResolversatomic.Bool// DisableLocalDNSOverrideViaNRPT indicates that the node's DNS manager should not// create a default (catch-all) Windows NRPT rule when "Override local DNS" is enabled.// Without this rule, Windows 8.1 and newer devices issue parallel DNS requests to DNS servers// associated with all network adapters, even when "Override local DNS" is enabled and/or// a Mullvad exit node is being used, resulting in DNS leaks.// We began creating this rule on 2024-06-14, and this knob// allows us to disable the new behavior remotely if needed.DisableLocalDNSOverrideViaNRPTatomic.Bool// DisableCaptivePortalDetection is whether the node should not perform captive portal detection// automatically when the network state changes.DisableCaptivePortalDetectionatomic.Bool// DisableSkipStatusQueue is whether the node should disable skipping// of queued netmap.NetworkMap between the controlclient and LocalBackend.// See tailscale/tailscale#14768.DisableSkipStatusQueueatomic.Bool}Knobs is the set of knobs that the control plane's coordination server canadjust at runtime.
func (*Knobs)AsDebugJSON¶added inv1.50.0
AsDebugJSON returns k as something that can be marshalled with json.Marshalfor debug.
func (*Knobs)UpdateFromNodeAttributes¶added inv1.50.0
func (k *Knobs) UpdateFromNodeAttributes(capMaptailcfg.NodeCapMap)
UpdateFromNodeAttributes updates k (if non-nil) based on the provided selfnode attributes (Node.Capabilities).