config

package
v0.0.0-...-b935d9b Latest Latest
Warning

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

Go to latest
Published: Jul 19, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Scenario

type Scenario struct {
	Rules []*SyscallRule
}

func ParseScenario

func ParseScenario(data []byte) (*Scenario, error)

func ParseScenarioFromFile

func ParseScenarioFromFile(path string) (*Scenario, error)

type SyscallMonkeyConfig

type SyscallMonkeyConfig struct {
	AttachPid    int    `short:"p" long:"attach" description:"Attach to the specified pid"`
	TargetName   string `short:"t" long:"target" description:"Attach to process matching this name"`
	ConfigPath   string `short:"c" long:"config" description:"Configuration file with desired scenario"`
	OutputPath   string `short:"o" long:"output" description:"Write the tracing output to the file (instead of stdout)"`
	PrintSummary bool   `short:"C" long:"summary" description:"Show verbose debug information"`
	Silent       bool   `short:"s" long:"silent" description:"Don't display tracing info"`
	TrailingArgs []string
	OutputFile   io.Writer
	Version      string
	Build        string
	TraceeStdin  io.Reader
	TraceeStdout io.Writer
	TraceeStderr io.Writer
	Pid          int
}

func ParseCommandLineFlags

func ParseCommandLineFlags(args []string) *SyscallMonkeyConfig

type SyscallRule

type SyscallRule struct {
	Name        string             `yaml:"name"`
	Probability *float64           `yaml:"probability"`
	Match       SyscallRuleMatch   `yaml:"match"`
	Delay       *SyscallRuleDelay  `yaml:"delay"`
	Modify      *SyscallRuleModify `yaml:"modify"`
}

type SyscallRuleArgs

type SyscallRuleArgs struct {
	Number int     `yaml:"number"`
	Int    *int64  `yaml:"int,omitempty"`
	Uint   *uint64 `yaml:"uint,omitempty"`
	String *string `yaml:"string,omitempty"`
}

type SyscallRuleDelay

type SyscallRuleDelay struct {
	Before *string `yaml:"before"`
	After  *string `yaml:"after"`
}

type SyscallRuleMatch

type SyscallRuleMatch struct {
	Name string             `yaml:"name"`
	Code *uint64            `yaml:"code"`
	Args []*SyscallRuleArgs `yaml:"args"`
}

type SyscallRuleModify

type SyscallRuleModify struct {
	Block  *bool              `yaml:"block"`
	Return *int               `yaml:"return"`
	Args   []*SyscallRuleArgs `yaml:"args"`
}

Jump to

Keyboard shortcuts

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