You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
👋 Thanks @sambetts-cisco --> I've transferred this issue over to grype. It looks like the cyclonedx-xml output by syft is correct. When we have a second we will investigate and see if we can submit a patch here.
./syft -o cyclonedx registry:gcr.io/google_containers/pause@sha256:927d98197ec1141a368550822d18fa1c60bdae27b78b0c004f705f548c07814f
This produces a valid CycloneDX XML SBOM:
Passing this into grype results in an error:
This should work correctly, and switching to cyclonedx-json for the same image works.
The root cause appears to be the code here: https://github.com/anchore/syft/blob/main/syft/formats/common/cyclonedxhelpers/decoder.go#L26
checking to see if bom.Components == nil. It might be a bug in cyclonedx-go producing inconsistent behaviour between XML and JSON.
The text was updated successfully, but these errors were encountered: