sbom

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 10, 2026 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package sbom describes packages as CycloneDX software bills of materials: what each package is, which charts and container images it installs, pinned by digest, and which packages it requires.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CycloneDX

func CycloneDX(pkgs []Package, o Options) ([]byte, error)

CycloneDX writes a CycloneDX 1.6 JSON document for the packages. The same packages and options always give the same bytes.

Types

type Options

type Options struct {
	// ToolVersion is the kubepkg version that made the document.
	ToolVersion string
	// Timestamp is when the described state was made, e.g. the index's
	// generation time, so the same packages give the same document.
	Timestamp time.Time
	// Name describes the whole set, e.g. a cluster or a bundle.
	Name string
}

Options shape the document.

type Package

type Package struct {
	Name, Version string
	Build         int32
	// Repository names where the version came from; Digest is its spec
	// digest in that repository's signed index.
	Repository, Digest string
	Spec               v1.PackageSourceSpec
	// Variant picks the requirements to record; default when empty.
	Variant string
}

Package is one package version to describe.

Jump to

Keyboard shortcuts

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