Documentation ¶
Index ¶
- func AggregateAllChecksBySpecID(multiResults []types.Results, cs ComplianceSpec) map[string]types.Results
- func MapSpecCheckIDToFilteredResults(result types.Result, checkIDs map[types.Scanner][]string) map[string]types.Results
- type ComplianceSpec
- type Control
- type ControlCheck
- type ControlStatus
- type Severity
- type Spec
- type SpecCheck
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AggregateAllChecksBySpecID ¶
func AggregateAllChecksBySpecID(multiResults []types.Results, cs ComplianceSpec) map[string]types.Results
AggregateAllChecksBySpecID aggregates all scan results and map it to spec ids
Types ¶
type ComplianceSpec ¶
type ComplianceSpec struct {
Spec Spec `yaml:"spec"`
}
ComplianceSpec represent the compliance specification
func GetComplianceSpec ¶
func GetComplianceSpec(specNameOrPath string) (ComplianceSpec, error)
GetComplianceSpec accepct compliance flag name/path and return builtin or file system loaded spec
type Control ¶
type Control struct { ID string `yaml:"id"` Name string `yaml:"name"` Description string `yaml:"description,omitempty"` Checks []SpecCheck `yaml:"checks"` Severity Severity `yaml:"severity"` DefaultStatus ControlStatus `yaml:"defaultStatus,omitempty"` }
Control represent the cps controls data and mapping checks
type ControlCheck ¶
type ControlCheck struct { ID string `yaml:"id"` Name string `yaml:"name"` Description string `yaml:"description,omitempty"` PassTotal int `yaml:"passTotal"` FailTotal int `yaml:"failTotal"` Severity Severity `yaml:"severity"` }
ControlCheck provides the result of conducting a single audit step.
type ControlStatus ¶
type ControlStatus string
const ( FailStatus ControlStatus = "FAIL" PassStatus ControlStatus = "PASS" WarnStatus ControlStatus = "WARN" )
Click to show internal directories.
Click to hide internal directories.