policystats

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Oct 22, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PolicyStatsMapName = "policy_stats"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type PolicyAction

type PolicyAction uint8
const (
	// NB: values below should match the ones in bpf/lib/policy_stats.h
	InvalidAction               PolicyAction = 0
	PolicyPost                  PolicyAction = 1
	PolicySignal                PolicyAction = 2
	PolicyMonitorSignal         PolicyAction = 3
	PolicyOverride              PolicyAction = 4
	PolicyMonitorOverride       PolicyAction = 5
	PolicyNotifyEnforcer        PolicyAction = 6
	PolicyMonitorNotifyEnforcer PolicyAction = 7
	PolicyActionsNr                          = 8
)

type PolicyStats

type PolicyStats struct {
	ActionsCount [PolicyActionsNr]uint64
}

func GetPolicyStats

func GetPolicyStats(tp tracingpolicy.TracingPolicy) (*PolicyStats, error)

func StatsFromBPFMap

func StatsFromBPFMap(fname string) (*PolicyStats, error)

Jump to

Keyboard shortcuts

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