mirror of
https://github.com/aquasecurity/trivy.git
synced 2025-12-12 07:40:48 -08:00
feat(sbom): scan sbom attestation in the rekor record (#2699)
Co-authored-by: knqyf263 <knqyf263@gmail.com>
This commit is contained in:
@@ -112,9 +112,10 @@ func (a Artifact) Decode(f io.Reader, format sbom.Format) (sbom.SBOM, error) {
|
||||
v = &cyclonedx.CycloneDX{SBOM: &bom}
|
||||
decoder = json.NewDecoder(f)
|
||||
case sbom.FormatAttestCycloneDXJSON:
|
||||
// in-toto attestation
|
||||
// => cosign predicate
|
||||
// => CycloneDX JSON
|
||||
// dsse envelope
|
||||
// => in-toto attestation
|
||||
// => cosign predicate
|
||||
// => CycloneDX JSON
|
||||
v = &attestation.Statement{
|
||||
Predicate: &attestation.CosignPredicate{
|
||||
Data: &cyclonedx.CycloneDX{SBOM: &bom},
|
||||
|
||||
Reference in New Issue
Block a user