bpf

package
v0.0.0-...-24c9e8f Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MAX_TARGETS = 64
)

Variables

This section is empty.

Functions

func AttachTC

func AttachTC(BpfObjs *BpfObjects, link netlink.Link) error

func AttachXDP

func AttachXDP(BpfObjs *BpfObjects, Ifindex int) (*xdp.Program, error)

func RemoveTC

func RemoveTC(ifName string, tcDir uint32) error

func TcPushtoMap

func TcPushtoMap(BpfObjs *BpfObjects, key uint16, targets []common.Node) error

Types

type BpfObjects

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

func LoadObjects

func LoadObjects() (*BpfObjects, error)

type TargetInfoInterface

type TargetInfoInterface interface {
	GetIp() uint32
	GetPort() uint16
	GetMac() [6]int8
}

Jump to

Keyboard shortcuts

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