Documentation
¶
Overview ¶
Package vulnerability defines the backend-agnostic contract for vulnerability scanning. Backends (e.g. Trustify, Quay) implement Scanner and return Finding DTOs owned by this package; the sync task converts them to persistence models centrally, so backends never depend on the store schema.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RequiresSBOMUpload ¶
func RequiresSBOMUpload(b config.VulnerabilityBackend) bool
RequiresSBOMUpload reports whether the given (already-resolved) backend needs client-side SBOM upload. Unknown backends return false so callers default to "skip upload".
Types ¶
type BackendCapabilities ¶
type BackendCapabilities struct {
// RequiresSBOMUpload reports whether the backend needs client-side SBOM
// upload (e.g. Trustify) rather than indexing images natively (e.g. Quay).
RequiresSBOMUpload bool
}
BackendCapabilities describes static, compile-time properties of a vulnerability backend that consumers need without constructing a Scanner.
type Finding ¶
type Finding struct {
CveID string
ImageDigest string
Severity string
CvssScore *float64
Status string
Issuer *Issuer
AdvisoryID *string
Description string
PublishedAt *time.Time
}
Finding is a backend-agnostic vulnerability finding for a single image digest.
type ImageRef ¶
ImageRef pairs a deployed image's digest with its full image reference. Digest is always populated; Image may be empty when a device reports a digest but no image reference.