process

package
v1.19.0 Latest Latest
Warning

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

Go to latest
Published: Dec 9, 2024 License: GPL-3.0 Imports: 17 Imported by: 1

Documentation

Index

Constants

View Source
const (
	FindProcessAlways = "always"
	FindProcessStrict = "strict"
	FindProcessOff    = "off"
)
View Source
const (
	TCP = "tcp"
	UDP = "udp"
)
View Source
const (
	SOCK_DIAG_BY_FAMILY = 20
)

Variables

View Source
var (
	ErrInvalidNetwork     = errors.New("invalid network")
	ErrPlatformNotSupport = errors.New("not support on this platform")
	ErrNotFound           = errors.New("process not found")
)

Functions

func FindPackageName

func FindPackageName(metadata *C.Metadata) (string, error)

func FindProcessName

func FindProcessName(network string, srcIP netip.Addr, srcPort int) (uint32, string, error)

Types

type FindProcessMode

type FindProcessMode string

func (FindProcessMode) Always

func (m FindProcessMode) Always() bool

func (FindProcessMode) Off

func (m FindProcessMode) Off() bool

func (*FindProcessMode) Set

func (m *FindProcessMode) Set(value string) error

func (*FindProcessMode) UnmarshalJSON

func (m *FindProcessMode) UnmarshalJSON(data []byte) error

func (*FindProcessMode) UnmarshalYAML

func (m *FindProcessMode) UnmarshalYAML(unmarshal func(any) error) error

type PackageNameResolver added in v1.18.7

type PackageNameResolver func(metadata *C.Metadata) (string, error)

PackageNameResolver never change type traits because it's used in CMFA

var DefaultPackageNameResolver PackageNameResolver

DefaultPackageNameResolver never change type traits because it's used in CMFA

Jump to

Keyboard shortcuts

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