Help us shape the future of Go! Take the 2026 Go Developer Survey

bom

package
v1.41.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenerateSbomForTarget

func GenerateSbomForTarget(generator SbomGenerator, params SbomGeneratorParams)

Types

type SbomGenerator

type SbomGenerator interface {
	WithOptions(options ...SbomGeneratorOption) SbomGenerator
	// PrepareGenerator prepares the generator for SBOM generation, should be called once before generating SBOMs.
	PrepareGenerator() error
	// GenerateSbom generates a CycloneDX SBOM for the given target.
	GenerateSbom(target results.ScanTarget) (*cyclonedx.BOM, error)
	// CleanUp cleans up any resources used by the generator, should be called after all SBOMs are generated.
	CleanUp() error
}

SbomGenerator is an interface for generating SBOMs from different sources.

type SbomGeneratorOption

type SbomGeneratorOption func(sg SbomGenerator)

type SbomGeneratorParams

type SbomGeneratorParams struct {
	Target               *results.TargetResults
	TotalTargets         int
	AllowPartialResults  bool
	ScanResultsOutputDir string

	DiffMode              bool
	TargetResultToCompare *results.TargetResults
}

Jump to

Keyboard shortcuts

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