-
Notifications
You must be signed in to change notification settings - Fork 217
feat(sign): support for sigstore bundle format #4369
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Brandt Keller <[email protected]>
✅ Deploy Preview for zarf-docs ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Codecov Report❌ Patch coverage is
🚀 New features to boost your workflow:
|
| // Note: this is the backwards compatible behavior | ||
| // this will change in the future | ||
| // Legacy signature found | ||
| l.Warn("non-bundle format signature is being deprecated in favor of the sigstore bundle format") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note the intent to deprecate the standard signature file at some point in the future. Allowing backwards compatibility while shifting all new package creations to using the bundle format.
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Signed-off-by: Brandt Keller <[email protected]>
Description
Migrates Zarf package signing to the Sigstore bundle format, aligning with Cosign v3 standards and improving signature portability and verification capabilities.
Changes
The signing implementation now defaults to
NewBundleFormat: trueand generates both legacy signature files and the new bundle format (saved aszarf.bundle.sig). TheSignPackage()function automatically configures the bundle path through the BundlePath option, ensuring all signing operations produce both formats for backward compatibility.Verification logic implements a fallback strategy that prefers the bundle format over legacy signatures. When verifying packages, the system first checks for a bundle file, and if not found, falls back to the legacy signature format with a deprecation warning to inform users of the transition. Validation Package integrity checks now exclude bundle files from validation, treating them similarly to how legacy signature files are handled to prevent false validation errors.
The implementation maintains dual format support by generating both bundle and legacy signatures during signing operations. This enables a graceful migration path where verification prefers the modern bundle format but seamlessly falls back to legacy signatures with appropriate warnings. The bundle format is now enabled by default, aligning Zarf with Cosign v3 standards.
The bundle format significantly improves verification capabilities by including timestamps and transparency log entries, which enables verification of packages signed with short-lived certificates even after expiration. Existing packages with legacy signatures remain fully functional while new signatures automatically use the modern format. This sets the foundation for eventually deprecating legacy signature support.
Related Issue
Fixes #4296
Fixes #4276
Checklist before merging