Skip to content
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

Proposal: Include raw Rekor Bundle in TransparencyLogEntry #9

Closed
codysoyland opened this issue Nov 3, 2022 · 3 comments · Fixed by #10
Closed

Proposal: Include raw Rekor Bundle in TransparencyLogEntry #9

codysoyland opened this issue Nov 3, 2022 · 3 comments · Fixed by #10
Labels
enhancement New feature or request

Comments

@codysoyland
Copy link
Member

Description

The bundle spec includes transparency log entries. In earlier discussions and the unmerged verification documentation, I think we agreed that IF a log entry is provided in the bundle, we MUST perform a successful SET verification (inclusion promise).

The SET verification requires 6 pieces of data:

  • canonicalized Rekor entry
  • integrated time
  • log index
  • log id
  • Rekor's public key
  • signature (known as the SET)

All of the above fields are included in the bundle except for the canonicalized Rekor entry. It was decided in the original proposal to reconstruct it from other data in the bundle, and by adding KindVersion to hint to the verifier which entry version to reconstruct. I believe this decision was made due to the fact that the intoto type would duplicate the DSSE in the bundle, producing a larger file size due to the redundant data.

Unfortunately, we still lack enough information to deterministically reproduce all Rekor entries. This was called out in the original proposal, but it was believed that we could reconstruct hashedRekord and intoto entries, which I understand to be the only supported entry types for the bundle. In fact, the intoto type still has an ambiguous field, the hash value which is calculated over the DSSE envelope. Rekor does not enforce any canonicalization of the DSSE used to produce the hash in the intoto v0.0.2 type, therefore, current intoto v0.0.2 entries cannot be verified without the raw bytes of the DSSE, which are not included in the bundle.

Additionally, it is a large burden to place on non-Go clients to reproduce the behavior of all the supported Rekor entry types, and I believe this will lead to verifiers that don't follow spec.

In my opinion, we should just capture the raw Rekor entry in the TransparencyLogEntry.

Alternatives:

  • We can just leave it as-is and require online verification for Rekor entries, but that kinda breaks the goal of offline verification of these bundles.
  • We can use TSA countersignatures to verify the signature was produced while the certificate was valid, which offers much of the same level of authenticity
@codysoyland
Copy link
Member Author

Just saw that Bob did acknowledge that the user-supplied hash in intoto v0.0.2 is a bug and should be fixed in v0.0.3: sigstore/rekor#1162 (comment)

@kommendorkapten
Copy link
Member

Another thing that @bdehamer found that will make it hard to reconstruct the Rekor entry: sigstore/rekor#1170

@asraa
Copy link
Contributor

asraa commented Nov 4, 2022

Maybe this is a 2 step:

1.Capture the canoncalized rekor entry in the bundle. Tell clients to validate the signatures are equal to prove "matching bundle".
2. In Rekor v2, we may change this either by simplifying types OR by simplifying the SET content.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants