pluginexec

package
v0.1.6 Latest Latest
Warning

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

Go to latest
Published: May 28, 2026 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ControlledPath = "/usr/local/bin:/usr/bin:/bin"

	MaxEnvValueBytes = 16 * 1024
)

Variables

This section is empty.

Functions

This section is empty.

Types

type DefaultRunner

type DefaultRunner struct{}

func (DefaultRunner) Run

func (DefaultRunner) Run(ctx context.Context, request Request) (Result, error)

type Error

type Error struct {
	Phase    string
	Reason   string
	Command  string
	ExitCode *int
	Err      error
}

func (*Error) Error

func (e *Error) Error() string

func (*Error) Unwrap

func (e *Error) Unwrap() error

type Execution

type Execution struct {
	Phase    string
	Command  string
	Duration time.Duration
}

type Request

type Request struct {
	SourceDir      string
	Config         pluginpolicy.ExecConfig
	ProtectedRoots []string
	EnvLookup      func(string) (string, bool)
}

type Result

type Result struct {
	Stdout     []byte
	Executions []Execution
}

type Runner

type Runner interface {
	Run(ctx context.Context, request Request) (Result, error)
}

Jump to

Keyboard shortcuts

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