bpf

package
v0.0.0-...-961797a Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2020 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MAX_MODULES    uint = 1024
	MAX_INTERFACES uint = 128
)

Variables

View Source
var (
	Debug = util.Debug
	Info  = util.Info
	Warn  = util.Warn
	Error = util.Error
)
View Source
var IomoduleH string = `` /* 1514-byte string literal not displayed */
View Source
var NetdevEgressC string = `` /* 369-byte string literal not displayed */
View Source
var NetdevRxC string = `` /* 372-byte string literal not displayed */
View Source
var NetdevTxC string = `` /* 132-byte string literal not displayed */
View Source
var PatchC string = `` /* 2982-byte string literal not displayed */
View Source
var WrapperC string = `` /* 1744-byte string literal not displayed */

Functions

This section is empty.

Types

type BpfModule

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

BpfModule type

func NewBpfModule

func NewBpfModule(code string, cflags []string) *BpfModule

func (*BpfModule) AttachKprobe

func (bpf *BpfModule) AttachKprobe(event string, fd int) error

func (*BpfModule) AttachKretprobe

func (bpf *BpfModule) AttachKretprobe(event string, fd int) error

func (*BpfModule) Close

func (bpf *BpfModule) Close()

func (*BpfModule) InitRxHandler

func (bpf *BpfModule) InitRxHandler() (int, error)

func (*BpfModule) Load

func (bpf *BpfModule) Load(name string, progType int) (int, error)

func (*BpfModule) LoadKprobe

func (bpf *BpfModule) LoadKprobe(name string) (int, error)

func (*BpfModule) LoadNet

func (bpf *BpfModule) LoadNet(name string) (int, error)

func (*BpfModule) TableDesc

func (bpf *BpfModule) TableDesc(id uint64) map[string]interface{}

func (*BpfModule) TableId

func (bpf *BpfModule) TableId(name string) C.size_t

func (*BpfModule) TableIter

func (bpf *BpfModule) TableIter() <-chan map[string]interface{}

func (*BpfModule) TableSize

func (bpf *BpfModule) TableSize() uint64

type BpfTable

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

func NewBpfTable

func NewBpfTable(id C.size_t, module *BpfModule) *BpfTable

func (*BpfTable) Config

func (table *BpfTable) Config() map[string]interface{}

func (*BpfTable) Delete

func (table *BpfTable) Delete(keyStr string) error

func (*BpfTable) Get

func (table *BpfTable) Get(keyStr string) (interface{}, bool)

Get takes a key and returns the value or nil, and an 'ok' style indicator

func (*BpfTable) ID

func (table *BpfTable) ID() string

func (*BpfTable) Iter

func (table *BpfTable) Iter() <-chan api.ModuleTableEntry

func (*BpfTable) Name

func (table *BpfTable) Name() string

func (*BpfTable) Set

func (table *BpfTable) Set(keyStr, leafStr string) error

Jump to

Keyboard shortcuts

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