tunnel

package
v1.15.4 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2024 License: Apache-2.0 Imports: 12 Imported by: 38

Documentation

Overview

+groupName=maps

Index

Constants

View Source
const (
	MapName = "cilium_tunnel_map"

	// MaxEntries is the maximum entries in the tunnel endpoint map
	MaxEntries = 65536
)

Variables

This section is empty.

Functions

func SetTunnelMap added in v0.15.7

func SetTunnelMap(m *Map)

SetTunnelMap sets the tunnel map. Only used for testing.

Types

type Map added in v0.15.7

type Map struct {
	*bpf.Map
}

Map implements tunnel connectivity configuration in the BPF datapath.

func NewTunnelMap added in v0.15.7

func NewTunnelMap(mapName string) *Map

NewTunnelMap returns a new tunnel map.

func TunnelMap added in v0.15.7

func TunnelMap() *Map

func (*Map) DeleteTunnelEndpoint added in v0.15.7

func (m *Map) DeleteTunnelEndpoint(prefix cmtypes.AddrCluster) error

DeleteTunnelEndpoint removes a prefix => tunnel-endpoint mapping

func (*Map) GetTunnelEndpoint added in v0.15.7

func (m *Map) GetTunnelEndpoint(prefix cmtypes.AddrCluster) (net.IP, error)

GetTunnelEndpoint retrieves a prefix => tunnel-endpoint mapping

func (*Map) SetTunnelEndpoint added in v0.15.7

func (m *Map) SetTunnelEndpoint(encryptKey uint8, prefix cmtypes.AddrCluster, endpoint net.IP) error

SetTunnelEndpoint adds/replaces a prefix => tunnel-endpoint mapping

func (*Map) SilentDeleteTunnelEndpoint added in v0.15.7

func (m *Map) SilentDeleteTunnelEndpoint(prefix cmtypes.AddrCluster) error

SilentDeleteTunnelEndpoint removes a prefix => tunnel-endpoint mapping. If the prefix is not found no error is returned.

type TunnelIP added in v0.15.7

type TunnelIP struct {
	// represents both IPv6 and IPv4 (in the lowest four bytes)
	IP     types.IPv6 `align:"$union0"`
	Family uint8      `align:"family"`
}

+k8s:deepcopy-gen=true

func (*TunnelIP) DeepCopy added in v0.15.7

func (in *TunnelIP) DeepCopy() *TunnelIP

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TunnelIP.

func (*TunnelIP) DeepCopyInto added in v0.15.7

func (in *TunnelIP) DeepCopyInto(out *TunnelIP)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TunnelKey added in v0.15.7

type TunnelKey struct {
	TunnelIP
	Pad       uint8  `align:"pad"`
	ClusterID uint16 `align:"cluster_id"`
}

func (*TunnelKey) New added in v0.15.7

func (k *TunnelKey) New() bpf.MapKey

func (TunnelKey) String added in v0.15.7

func (k TunnelKey) String() string

String provides a string representation of the TunnelKey.

type TunnelValue added in v0.15.7

type TunnelValue struct {
	TunnelIP
	Key uint8  `align:"key"`
	Pad uint16 `align:"pad"`
}

func (*TunnelValue) New added in v0.15.7

func (k *TunnelValue) New() bpf.MapValue

func (TunnelValue) String added in v0.15.7

func (k TunnelValue) String() string

String provides a string representation of the TunnelValue.

Jump to

Keyboard shortcuts

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