Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Evaluation ¶ added in v0.1.2
type Evaluation struct { Input string `json:"input" yaml:"input"` License internal.License `json:"license" yaml:"license"` Package internal.Package `json:"package" yaml:"package"` Passed bool `json:"passed" yaml:"passed"` Reasons []string `json:"reasons" yaml:"reasons"` }
func NewEvaluation ¶ added in v0.1.2
func NewEvaluation(input string, le evalutation.LicenseEvaluation) Evaluation
type Report ¶
type Report struct { ReportID string Results evalutation.Results Config ReportConfig Timestamp string Monitor *event.ManualStagedProgress // contains filtered or unexported fields }
Report presents the results of a grant check command `grant alpine:latest ./foo` The above command will have two results. The first result is easy. Generate an SBOM for alpine:latest and run the policy against it. The second result is a little more complicated. Visit each leaf of ./foo and check for licenses, sbom, or archives. Results are composed of a case its evaluations. The case is the total of SBOM/Licenses generated from the user request. The evaluations are the individual assessments of the policy against the packages/licenses in the case.
func NewReport ¶
func NewReport(rc ReportConfig, userRequests ...string) (*Report, error)
NewReport will generate a new report for the given format for the check command The supplied policy is applied to all user requests. If no policy is provided, the default policy will be used If no requests are provided, an empty report will be generated If a request is provided, but the sbom cannot be generated, the source will be ignored and an error will be returned Where do we render packages that had no licenses?
func (*Report) HasFailures ¶ added in v0.1.2
type ReportConfig ¶
type ReportConfig struct { Policy grant.Policy Options internal.ReportOptions Monitor *event.ManualStagedProgress }