Encode Rekor v2 DSSE envelopes as hashedrekord#627
Merged
Hayden-IO merged 3 commits intoJun 2, 2026
Conversation
771403b to
659cd48
Compare
Hayden-IO
reviewed
May 14, 2026
251d323 to
ba0a097
Compare
codysoyland
commented
May 27, 2026
Comment on lines
-214
to
-217
| case crypto.SHA3_256: | ||
| return protocommon.HashAlgorithm_SHA3_256, nil | ||
| case crypto.SHA3_384: | ||
| return protocommon.HashAlgorithm_SHA3_384, nil |
Member
Author
There was a problem hiding this comment.
Removed as these were marked deprecated in protobuf-specs/protos/sigstore_common.proto
Hayden-IO
reviewed
May 27, 2026
| - run: go build -o conformance test/conformance/main.go | ||
|
|
||
| - uses: sigstore/sigstore-conformance@4d66ba3cb0c9c95f705c757c0f5e226d3f4d5151 # v0.0.27 | ||
| - uses: sigstore/sigstore-conformance@7fc09c1747fbbc49996ef2f43bb740ca60ec944f # non-release commit that includes hashedrekord dsse test bundles |
Contributor
There was a problem hiding this comment.
Can we get a new release of sigstore-conformance out before this is merged?
Member
Author
There was a problem hiding this comment.
sigstore-conformance PR is ready: sigstore/sigstore-conformance#371
I do not have permission to merge or release there btw.
DSSE envelope bundles are now represented as hashedrekord Rekor entries instead of the dsse entry type. The entry digest is computed over the DSSE PAE encoding using the signing algorithm's externalized hash function. Verification reconstructs the entry hash from bundle contents and verifies inclusion against it. Includes ed25519ph support and test coverage. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Cody Soyland <cody.soyland@chainguard.dev>
ba0a097 to
17e1bd3
Compare
Hayden-IO
previously approved these changes
Jun 1, 2026
Hayden-IO
left a comment
Contributor
There was a problem hiding this comment.
Thanks for getting this done! LGTM, just a non-blocking comment.
| // always uploaded as a hashedrekord whose digest covers the envelope's | ||
| // PAE. The hash function matches the signing algorithm (e.g. | ||
| // ECDSA P-256 → SHA-256, P-384 → SHA-384). | ||
| if len(dsseEnvelope.Signatures) == 0 { |
Contributor
There was a problem hiding this comment.
@loosebazooka Where did you land on whether or not to enforce one signature in the DSSE?
| if err != nil { | ||
| return nil, fmt.Errorf("marshaling rekor v2 entry: %w", err) | ||
| } | ||
| // Mirror the server-side pipeline (rekor-tiles internal/server/service.go): |
Contributor
There was a problem hiding this comment.
nit, some of these comments here are a little verbose
Signed-off-by: Cody Soyland <cody.soyland@chainguard.dev> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Cody Soyland <cody.soyland@chainguard.dev>
Signed-off-by: Cody Soyland <cody.soyland@chainguard.dev> Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com> Signed-off-by: Cody Soyland <cody.soyland@chainguard.dev>
6f6afb5
Hayden-IO
approved these changes
Jun 2, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements the encoding proposed in sigstore/architecture-docs#63 (rekor-v2-spec §6.1.4): on Rekor v2, DSSE envelopes are uploaded as a
hashedrekordwhose digest coversHash(PAE(payloadType, payload)), whereHashis derived from the signing algorithm (ECDSA P-256 → SHA-256, P-384 → SHA-384, etc.; ed25519 must use ed25519ph).On the verification side, the canonicalized Rekor entry body is now reconstructed from the bundle contents rather than relying on the body in the bundle.
Rekor v1 behavior is unchanged.