Skip to content

Conversation

@falcorocks
Copy link

@falcorocks falcorocks commented Oct 13, 2025

Closes #1895

Summary

Some provenance attestation implementation, for instance Google Cloud Build, store attestations using the OCI 1.1 referrers API rather than the traditional <subject digest>.att naming scheme. As is, the policy controller is thus unable to verify valid in-toto provenance attestations generated by Google Cloud Build. This is demonstrated in #1895.

This PR Implements OCI 1.1 referrers API for discovering attestations with automatic fallback to legacy tag-based discovery. This enables policy-controller to work with modern OCI 1.1 registries while maintaining backward compatibility, regardless if the new sigstore bundle format is used or not.

Technical implementation:

  • Uses ociremote.Referrers() to discover attestation artifacts
  • Filters by artifact types: in-toto, slsa, provenance, attestation, dsse
  • Processes DSSE envelopes and creates compatible oci.Signature objects
  • Maintains proper payload format for AttestationToPayloadJSON compatibility

BEFORE

Image

AFTER

Screenshot 2025-10-13 at 16 52 14

Release Note

  • Add 'enable-oci11' configuration option
  • Implement custom OCI 1.1 referrers API discovery in validAttestations()
  • Add CLI flag '--enable-oci11' to policy-tester for testing
  • Automatic fallback to legacy cosign discovery when OCI 1.1 fails

Documentation

@falcorocks falcorocks force-pushed the falcorocks/add-oci11-support branch 2 times, most recently from 751857e to f0a9af2 Compare October 13, 2025 13:10
Implements OCI 1.1 referrers API for discovering attestations with automatic
fallback to legacy tag-based discovery. This enables policy-controller to work
with modern OCI 1.1 registries while maintaining backward compatibility.

- Add 'enable-oci11' configuration option (disabled by default)
- Implement OCI 1.1 referrers API discovery with fallback
- Add CLI flag '--enable-oci11' to policy-tester for testing

Signed-off-by: falcorocks <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Policy controller cannot work with OCI 1.1 stored attestations

1 participant