config

package
v1.2.5 Latest Latest
Warning

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

Go to latest
Published: Dec 22, 2021 License: LGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var FlagSet *pflag.FlagSet

Fs is the "filesystem" in which configuration and rules are found. This can be provided through a ZIP file appended to the binary.

Functions

func Init

func Init() error

Types

type CollectConfig added in v1.2.0

type CollectConfig struct {
	Disabled bool     `yaml:"disabled"`
	File     string   `yaml:"file"`
	Password string   `yaml:"password"`
	MaxSize  FileSize `yaml:"max-size"`
}

type FileSize added in v1.2.0

type FileSize int64

func (*FileSize) Set added in v1.2.0

func (f *FileSize) Set(val string) error

func (FileSize) String added in v1.2.0

func (f FileSize) String() string

func (*FileSize) Type added in v1.2.0

func (f *FileSize) Type() string

func (*FileSize) UnmarshalText added in v1.2.0

func (f *FileSize) UnmarshalText(text []byte) error

type GlobalConfig added in v1.2.0

type GlobalConfig struct {
	MaxFileSize        FileSize                 `yaml:"max-file-size"`
	Paths              StringSlice              `yaml:"paths"`
	ProcIgnoreNames    StringSlice              `yaml:"proc-ignore-names"`
	ReportTargets      StringSlice              `yaml:"report"`
	EvidenceCollection CollectConfig            `yaml:"evidence-collector"`
	Hostname           string                   `yaml:"hostname"`
	HighPriority       bool                     `yaml:"high-priority"`
	UI                 UIConfig                 `yaml:"ui"`
	RulesetMarker      string                   `yaml:"ruleset-marker"`
	SystemScanners     map[string]ScannerConfig `yaml:"system"`
	FileScanners       map[string]ScannerConfig `yaml:"file"`
	ProcScanners       map[string]ScannerConfig `yaml:"proc"`
}
var Global GlobalConfig

type ScannerConfig added in v1.2.0

type ScannerConfig struct {
	Disabled bool      `yaml:"disabled"`
	Config   yaml.Node `yaml:"config"`
}

type StringSlice added in v1.2.0

type StringSlice []string

StringSlice is a simpler version of the type backing pflag.StringSlice etc. whose Set method has "append" semantics.

func (*StringSlice) Set added in v1.2.0

func (s *StringSlice) Set(val string) (err error)

func (*StringSlice) String added in v1.2.0

func (s *StringSlice) String() string

func (StringSlice) Type added in v1.2.0

func (s StringSlice) Type() string

func (*StringSlice) UnmarshalText added in v1.2.0

func (s *StringSlice) UnmarshalText(text []byte) error

type UIConfig added in v1.2.0

type UIConfig struct {
	PromptOnExit bool `yaml:"prompt-on-exit"`
}

Jump to

Keyboard shortcuts

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