Documentation
¶
Index ¶
- func AreLicensesValid(licenses []licenses.License) bool
- func CheckAuthors(authors []sbom.GetAuthor) (string, bool)
- func CheckCopyright(cp string) (string, bool)
- func CheckCpes(cpes []cpe.CPE) (string, bool)
- func CheckHash(checksums []sbom.GetChecksum) (string, bool, bool)
- func CheckManufacturer(manufacturer sbom.GetManufacturer) (string, bool)
- func CheckOmnibor(omni []omniborid.OMNIBORID) (string, bool)
- func CheckPrimaryDependenciesInComponentList(dependencies []string, componentList map[string]bool) bool
- func CheckPurls(purls []purl.PURL) (string, bool)
- func CheckSupplier(supplier sbom.GetSupplier) (string, bool)
- func CheckSwhid(swhid []swhid.SWHID) (string, bool)
- func CheckSwid(swid []swid.SWID) (string, bool)
- func CheckTimestamp(timestamp string) (string, bool)
- func CheckTools(tools []sbom.GetTool) (string, bool)
- func ColorTable(table *tablewriter.Table, elementID, id string, elementResult string, ...) *tablewriter.Table
- func ComponentsLists(doc sbom.Document) map[string]bool
- func ComponentsNamesMapToIDs(doc sbom.Document) map[string]string
- func ConvertMapToString(m map[string]string) string
- func DecodeBase64URLEncodingToInt(input string) int
- func DecodeBigInt(input []byte) *big.Int
- func GetAllPrimaryComponentDependencies(doc sbom.Document) []string
- func GetDependenciesByName(dependencies []string, compIDWithName map[string]string) []string
- func GetID(componentID string) string
- func GetScoreColor(score float64) tablewriter.Colors
- func GetSignatureBundle(ctx context.Context, sbomFile, signature, publicKey string) (string, string, string, error)
- func HashSBOM(sbomPath string) ([]byte, error)
- func IsComponentPartOfPrimaryDependency(primaryCompDeps []string, comp string) bool
- func MapPrimaryDependencies(doc sbom.Document) map[string]bool
- func PublicKeyToPEM(pub *rsa.PublicKey) []byte
- func RemoveFileIfExists(filePath string)
- func RetrieveSignatureFromSBOM(ctx context.Context, sbomFile string) (string, string, string, error)
- func SetHeaderColor(table *tablewriter.Table, header int)
- func UniqueElementID(component sbom.GetComponent) string
- func VerifySignature(pubKeyData []byte, sbomPath, signaturePath string) (bool, error)
- func WrapLongTextIntoMulti(input string, maxWidth int) string
- func WrapText(input string, maxWidth int) string
- type PublicKey
- type SBOM
- type Signature
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AreLicensesValid ¶ added in v1.0.0
func CheckCopyright ¶
func CheckManufacturer ¶
func CheckManufacturer(manufacturer sbom.GetManufacturer) (string, bool)
func CheckPrimaryDependenciesInComponentList ¶
func CheckPrimaryDependenciesInComponentList(dependencies []string, componentList map[string]bool) bool
CheckPrimaryDependenciesInComponentList checks if all primary dependencies are part of the component list.
func CheckSupplier ¶
func CheckSupplier(supplier sbom.GetSupplier) (string, bool)
func CheckTimestamp ¶
func ColorTable ¶ added in v1.0.0
func ColorTable(table *tablewriter.Table, elementID, id string, elementResult string, dataFields string, score float64, columnWidth int) *tablewriter.Table
func ComponentsLists ¶
ComponentsLists return component lists as a map
func ComponentsNamesMapToIDs ¶
ComponentsNamesMapToIDs returns map of component ID as key and component Name as value
func ConvertMapToString ¶
ConvertMapToString converts a map of type map[string]string into a string representation where each key-value pair is formatted as "key:value".
func DecodeBase64URLEncodingToInt ¶ added in v1.0.0
func DecodeBigInt ¶ added in v1.0.0
func GetAllPrimaryComponentDependencies ¶
GetAllPrimaryComponentDependencies return all list of primary component dependencies by it's ID.
func GetDependenciesByName ¶
GetDependenciesByName returns the names of all dependencies based on their IDs.
func GetScoreColor ¶ added in v1.0.0
func GetScoreColor(score float64) tablewriter.Colors
func GetSignatureBundle ¶ added in v1.0.8
func MapPrimaryDependencies ¶
MapPrimaryDependencies returns a map of all primary dependencies with bool. Primary dependencies marked as true else false.
func PublicKeyToPEM ¶ added in v1.0.0
func RemoveFileIfExists ¶ added in v1.0.0
func RemoveFileIfExists(filePath string)
func RetrieveSignatureFromSBOM ¶ added in v1.0.0
func SetHeaderColor ¶ added in v1.0.0
func SetHeaderColor(table *tablewriter.Table, header int)
func UniqueElementID ¶
func UniqueElementID(component sbom.GetComponent) string
func VerifySignature ¶ added in v1.0.0
func WrapLongTextIntoMulti ¶ added in v1.0.4
convert long text into multiple lines