types

package
v0.56.3 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CombinedOut

type CombinedOut map[string]TrivyOut

CombinedOut represents the output of multiple Trivy runs (useful when using the Trivy Smithy tool to scan multiple images); the key is the name of the image file that was scanned.

type TrivyCVSS

type TrivyCVSS struct {
	Nvd TrivyNvd `json:"nvd"`
}

TrivyCVSS wraps Trivy CVSS info struct.

type TrivyNvd

type TrivyNvd struct {
	V3Vector string  `json:"V3Vector"`
	V3Score  float64 `json:"V3Score"`
}

TrivyNvd wraps Trivy Nvd structure inside the CVSS struct.

type TrivyOut

type TrivyOut struct {
	Results []TrivyResults `json:"Results"`
}

TrivyOut represents the output of a trivy run that we care about.

type TrivyPkgIdentifier

type TrivyPkgIdentifier struct {
	PURL string `json:"PURL"`
	UID  string `json:"UID"`
}

TrivyPkgIdentifier represents the package identifier in the trivy output.

type TrivyResults

type TrivyResults struct {
	Vulnerable []*TrivyVulnerability `json:"Vulnerabilities"`
	Target     string
	Type       string
}

TrivyResults is a single result/finding.

type TrivyVulnerability

type TrivyVulnerability struct {
	CVE              string             `json:"VulnerabilityID"`
	PkgName          string             `json:"PkgName"`
	InstalledVersion string             `json:"InstalledVersion"`
	FixedVersion     string             `json:"FixedVersion"`
	PrimaryURL       string             `json:"PrimaryURL"`
	Title            string             `json:"Title"`
	Description      string             `json:"Description"`
	Severity         string             `json:"Severity"`
	CweIDs           []string           `json:"CweIds"`
	CVSS             TrivyCVSS          `json:"CVSS"`
	PkgIdentifier    TrivyPkgIdentifier `json:"PkgIdentifier"`
}

TrivyVulnerability represents a trivy vulnerability section with only the fields that we care about.

Jump to

Keyboard shortcuts

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