encrypt

package
v1.16.0-rc.2 Latest Latest
Warning

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

Go to latest
Published: Jul 15, 2024 License: Apache-2.0 Imports: 5 Imported by: 8

Documentation

Overview

Package encrypt represents the nodes current encryption state. It is used by the datapath to learn current encryption configuration and managed by golang linux datapath ./pkg/datapath/linux/ objects. This will reflect any key rotations/updates. +groupName=maps

Index

Constants

View Source
const (
	// MapName name of map used to pin map for datapath
	MapName = "cilium_encrypt_state"

	// MaxEntries represents the maximum number of current encryption contexts
	MaxEntries = 1
)

Variables

This section is empty.

Functions

func MapCreate

func MapCreate() error

MapCreate will create an encrypt map that is ready for use.

func MapUpdateContext

func MapUpdateContext(ctxID uint32, keyID uint8) error

MapUpdateContext updates the encrypt state with ctxID to use the new keyID

func MapUpdateContextWithMap added in v1.16.0

func MapUpdateContextWithMap(m *bpf.Map, ctxID uint32, keyID uint8) error

MapUpdateContextWithMap updates the encrypt state with ctxID to use the new keyID with the map as its argument.

This is primarily used in tests.

func NewMap added in v1.16.0

func NewMap(MapName string) *bpf.Map

NewMap will construct a bpf.Map that is not open or created yet.

Types

type EncryptKey

type EncryptKey struct {
	// contains filtered or unexported fields
}

EncryptKey is the context ID for the encryption session

func (EncryptKey) New

func (k EncryptKey) New() bpf.MapKey

func (EncryptKey) String

func (k EncryptKey) String() string

String pretty print the EncryptKey

type EncryptValue

type EncryptValue struct {
	// contains filtered or unexported fields
}

EncryptValue is ID assigned to the keys

func (EncryptValue) New

func (v EncryptValue) New() bpf.MapValue

func (EncryptValue) String

func (v EncryptValue) String() string

String pretty print the encryption key index.

Jump to

Keyboard shortcuts

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