Documentation
¶
Index ¶
- func FirstOf[K interface{}](inputs ...*K) *K
- func MergeMaps[K comparable, V comparable](maps ...map[K]V) map[K]V
- func Pointer[K interface{}](input K) *K
- type Activity
- type EvalOutput
- type Labels
- type Link
- type Package
- type Policy
- type PolicyManager
- type PolicyProcessor
- type Result
- type Risk
- type Step
- type Violation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FirstOf ¶ added in v0.1.7
func FirstOf[K interface{}](inputs ...*K) *K
FirstOf will return the first pointer which is not null. This is used when multiple optional options exist to fill a field, but they have an order of priority
func MergeMaps ¶ added in v0.1.7
func MergeMaps[K comparable, V comparable](maps ...map[K]V) map[K]V
Types ¶
type EvalOutput ¶
type EvalOutput struct {
Title *string `mapstructure:"title,omitempty"`
Description *string `mapstructure:"description,omitempty"`
Remarks *string `mapstructure:"remarks,omitempty"`
Labels *map[string]string `mapstructure:"labels,omitempty"`
Violations []Violation
AdditionalVariables map[string]interface{}
}
type PolicyManager ¶
type PolicyManager struct {
// contains filtered or unexported fields
}
type PolicyProcessor ¶ added in v0.1.7
type PolicyProcessor struct {
// contains filtered or unexported fields
}
func NewPolicyProcessor ¶ added in v0.1.7
func NewPolicyProcessor( logger hclog.Logger, labels map[string]string, subjects []*proto.Subject, components []*proto.Component, inventoryItems []*proto.InventoryItem, actors []*proto.OriginActor, activities []*proto.Activity, ) *PolicyProcessor
func (*PolicyProcessor) GenerateResults ¶ added in v0.1.7
type Result ¶
type Result struct {
Policy Policy
*EvalOutput
}
Click to show internal directories.
Click to hide internal directories.