Help us shape the future of Go! Take the 2026 Go Developer Survey

types

package
v1.20.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 23, 2026 License: Apache-2.0 Imports: 1 Imported by: 3

Documentation

Overview

Common WireGuard types and constants

Index

Constants

View Source
const (
	EnableWireguard              = "enable-wireguard"
	WireguardPersistentKeepalive = "wireguard-persistent-keepalive"
	WireguardTrackAllIPsFallback = "wireguard-track-all-ips-fallback"
	NodeEncryptionOptOutLabels   = "node-encryption-opt-out-labels"
)

Command-line flags for WireGuard.

View Source
const (
	// ListenPort is the port on which the WireGuard tunnel device listens on
	ListenPort = 51871
	// IfaceName is the name of the WireGuard tunnel device
	IfaceName = "cilium_wg0"
	// PrivKeyFilename is the name of the WireGuard private key file
	PrivKeyFilename = "cilium_wg0.key"
	// StaticEncryptKey is used in the IPCache to mark entries for which we
	// want to enable WireGuard encryption
	StaticEncryptKey = uint8(0xFF)
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Agent added in v1.20.0

type Agent interface {
	Enabled() bool
	Status(withPeers bool) (*models.WireguardStatus, error)
	IfaceIndex() (uint32, error)
	IfaceBufferMargins() (uint16, uint16, error)
}

Agent exports the Enabled and Status commands from the agent.

type Config added in v1.20.0

type Config interface {
	Enabled() bool
}

Config exports the Enabled method rather than the whole config. This is useful when the whole agent is not needed. See Agent otherwise.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL