-
Notifications
You must be signed in to change notification settings - Fork 619
Add support for SigningConfig in sign/attest #4371
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
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4371 +/- ##
==========================================
- Coverage 40.10% 33.88% -6.22%
==========================================
Files 155 217 +62
Lines 10044 15341 +5297
==========================================
+ Hits 4028 5199 +1171
- Misses 5530 9473 +3943
- Partials 486 669 +183 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
1d07438
to
8dbe6bf
Compare
Putting this up for an early review. Only the last commit is new, the first two commits will be merged in other open PRs. I also am currently doing some manual testing. |
Testing against staging with a local zot instance: Sign:
Attest:
|
Note to reviewers: Going to take a pass over trying to reduce duplication. Edit: Reviewing the code, I'd rather not try to reduce duplication for now between sign and attest. These commands will be nearly identical post-Cosign v3, so I'd rather just remove one later on then try to determine a good API for shared logic between the two right now. |
This creates a wrapper around the Keypair interface when a SignerVerifier is provided for signing with KMS or any other provided keys. This also retains support for --issue-certificate to request a certificate for a managed key. Fixes sigstore#4327 Signed-off-by: Hayden <[email protected]>
This is for uniformity with sign/sign-blob. Signed-off-by: Hayden <[email protected]>
8dbe6bf
to
b8dd92f
Compare
Now, we can generate a SignerVerifier from a provided key without mandating that we also request a Fulcio certificate when "issue-certificate" is provided. Signed-off-by: Hayden <[email protected]>
This will indirectly add support for signing with Rekor v2, since signing will be handled by sigstore-go rather than Cosign. This also brings sign/attest up to par with sign-blob/attest-blob with respect to signing with a key and providing a trusted root when providing a signing config. This feature is gated behind one of two signing config flags, which in a later version of Cosign will be flipped to on by default. Signed-off-by: Hayden <[email protected]>
b8dd92f
to
ee986f2
Compare
Summary
This will indirectly add support for signing with Rekor v2, since signing will be handled by sigstore-go rather than Cosign.
This also brings sign/attest up to par with the recent changes to sign-blob/attest-blob, including signing with a key and providing a path to a trusted root when providing a signing config to verify after signing.
This feature is gated behind one of two signing config flags, which in a later version of Cosign will be flipped to on by default. Once this is the default, we'll be able to refactor the core signing and verification logic in Cosign, largely replacing it with sigstore-go.
Fixes #4324
Release Note
Documentation