models

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AuditResult

type AuditResult struct {
	NumOfExec    int
	NumOfSuccess int
}

AuditResult data

type Category

type Category struct {
	Name        string       `yaml:"name"`
	SubCategory *SubCategory `yaml:"sub_category"`
}

Category data model

type Check

type Check struct {
	BenchmarkType string     `yaml:"benchmark_type"`
	Categories    []Category `yaml:"categories"`
}

Check data model

type CheckTotals

type CheckTotals struct {
	Warn int
	Pass int
	Fail int
}

CheckTotals model

type SecurityCheck

type SecurityCheck struct {
	Name                 string   `mapstructure:"name" yaml:"name"`
	ProfileApplicability string   `mapstructure:"profile_applicability" yaml:"profile_applicability"`
	Description          string   `mapstructure:"description" yaml:"description"`
	CheckCommand         []string `mapstructure:"check_command" json:"check_command"`
	CheckType            string   `mapstructure:"check_type" yaml:"check_type"`
	Remediation          string   `mapstructure:"remediation" yaml:"remediation"`
	Impact               string   `mapstructure:"impact" yaml:"impact"`
	AdditionalInfo       string   `mapstructure:"additional_info" yaml:"additional_info"`
	References           []string `mapstructure:"references" yaml:"references"`
	DefaultValue         string   `mapstructure:"default_value" yaml:"default_value"`
	EvalExpr             string   `mapstructure:"eval_expr" yaml:"eval_expr"`
	PolicyName           string   `mapstructure:"policy_name" yaml:"policy_name"`
	EvalMessage          string   `mapstructure:"eval_message" yaml:"eval_message"`
	PolicyResult         eval.CmdEvalResult
	TestSucceed          bool
	CommandParams        map[int][]string
	Category             string
	NonApplicable        bool
	TestType             string `mapstructure:"type" yaml:"type"`
}

SecurityCheck data model

func (*SecurityCheck) UnmarshalYAML

func (at *SecurityCheck) UnmarshalYAML(unmarshal func(interface{}) error) error

UnmarshalYAML over unmarshall to add logic

type SubCategory

type SubCategory struct {
	Name   string           `yaml:"name"`
	Checks []*SecurityCheck `yaml:"security_checks"`
}

SubCategory data model

Jump to

Keyboard shortcuts

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