sbom

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Dec 13, 2022 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	InvalidFormat = errors.New("invalid format")
)
View Source
var (
	Providers = []SBOMReader{
		&SPDX{},
		&CycloneDX{},
	}
)

Functions

This section is empty.

Types

type CycloneDX

type CycloneDX struct{}

func (*CycloneDX) GetPackages

func (c *CycloneDX) GetPackages(r io.ReadSeeker, callback func(Identifier) error) error

func (*CycloneDX) Name

func (c *CycloneDX) Name() string

type Identifier

type Identifier struct {
	PURL string
}

Identifier is the identifier extracted from the SBOM.

type SBOMReader

type SBOMReader interface {
	Name() string
	GetPackages(io.ReadSeeker, func(Identifier) error) error
}

SBOMReader is an interface for all SBOM providers.

type SPDX

type SPDX struct{}

func (*SPDX) GetPackages

func (s *SPDX) GetPackages(r io.ReadSeeker, callback func(Identifier) error) error

func (*SPDX) Name

func (s *SPDX) Name() string

Jump to

Keyboard shortcuts

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