Documentation ¶
Index ¶
- func NewSet(resourceBlock block.Block) *resultSet
- type Annotation
- type Result
- func (res *Result) Annotations() []Annotation
- func (r *Result) Blocks() block.Blocks
- func (r *Result) HashCode() string
- func (res *Result) IsIgnored(workspace string) bool
- func (r *Result) IsOnAttribute() bool
- func (r *Result) Passed() bool
- func (r *Result) Range() block.Range
- func (r *Result) WithAttribute(attr block.Attribute) *Result
- func (r *Result) WithBlock(block block.Block) *Result
- func (r *Result) WithDescription(description string, parts ...interface{}) *Result
- func (r *Result) WithImpact(impact string) *Result
- func (r *Result) WithLegacyRuleID(id string) *Result
- func (r *Result) WithLink(link string) *Result
- func (r *Result) WithLinks(links []string) *Result
- func (r *Result) WithResolution(resolution string) *Result
- func (r *Result) WithRuleID(id string) *Result
- func (r *Result) WithRuleProvider(provider provider.Provider) *Result
- func (r *Result) WithRuleSummary(description string) *Result
- func (r *Result) WithSeverity(sev severity.Severity) *Result
- func (r *Result) WithStatus(status Status) *Result
- type Set
- type Status
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Annotation ¶ added in v0.52.0
type Result ¶
type Result struct { RuleID string `json:"rule_id"` LegacyRuleID string `json:"legacy_rule_id"` RuleSummary string `json:"rule_description"` RuleProvider provider.Provider `json:"rule_provider"` Impact string `json:"impact"` Resolution string `json:"resolution"` Links []string `json:"links"` Description string `json:"description"` RangeAnnotation string `json:"-"` Severity severity.Severity `json:"severity"` Status Status `json:"status"` Location block.Range `json:"location"` Resource string `json:"resource"` // contains filtered or unexported fields }
Result is a positive result for a security check. It encapsulates a code unique to the specific check it was raised by, a human-readable description and a range
func (*Result) Annotations ¶ added in v0.52.0
func (res *Result) Annotations() []Annotation
func (*Result) IsOnAttribute ¶ added in v0.52.0
func (*Result) WithAttribute ¶ added in v0.52.0
func (*Result) WithDescription ¶
func (*Result) WithImpact ¶
func (*Result) WithLegacyRuleID ¶ added in v0.50.0
func (*Result) WithResolution ¶
func (*Result) WithRuleID ¶
func (*Result) WithRuleProvider ¶
func (*Result) WithRuleSummary ¶
func (*Result) WithStatus ¶
type Set ¶
type Set interface { AddResult() *Result WithRuleID(id string) Set WithLegacyRuleID(id string) Set WithRuleSummary(description string) Set WithRuleProvider(provider provider.Provider) Set WithImpact(impact string) Set WithResolution(resolution string) Set WithLinks(links []string) Set All() []*Result }
Click to show internal directories.
Click to hide internal directories.