spec

package
v0.44.0 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2023 License: Apache-2.0 Imports: 13 Imported by: 1

Documentation

Index

Constants

View Source
const (
	FailStatus defsecTypes.ControlStatus = "FAIL"
	PassStatus defsecTypes.ControlStatus = "PASS"
	WarnStatus defsecTypes.ControlStatus = "WARN"
)

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

func MapSpecCheckIDToFilteredResults

func MapSpecCheckIDToFilteredResults(result types.Result, checkIDs map[types.Scanner][]string) map[string]types.Results

MapSpecCheckIDToFilteredResults map spec check id to filtered scan results

Types

type ComplianceSpec

type ComplianceSpec struct {
	Spec defsecTypes.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

func (*ComplianceSpec) CheckIDs

func (cs *ComplianceSpec) CheckIDs() map[types.Scanner][]string

CheckIDs return list of compliance check IDs

func (*ComplianceSpec) Scanners

func (cs *ComplianceSpec) Scanners() (types.Scanners, error)

Scanners reads spec control and determines the scanners by check ID prefix

type Severity

type Severity string

Jump to

Keyboard shortcuts

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