Use the publicKey field name in the bundle example - #451
Open
arpitjain099 wants to merge 1 commit into
Open
Conversation
The example shows publicKeyIdentifier, which is the message type name. The field in VerificationMaterial is dev.sigstore.common.v1.PublicKeyIdentifier public_key = 1 so protojson emits publicKey. The neighbouring X.509 example already uses the field name, certificate, rather than the type name, so this is the odd one out. Anyone hand-building a bundle from this page ends up with a key hint under a name no verifier reads. Signed-off-by: Arpit Jain <arpitjain099@gmail.com>
✅ Deploy Preview for docssigstore ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
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.
Closes #446. @mlschroe is right, and I checked it against the pinned spec rather than taking it on faith.
sigstore_bundle.protodeclares the oneof member as:oneof content { dev.sigstore.common.v1.PublicKeyIdentifier public_key = 1 [(google.api.field_behavior) = REQUIRED]; dev.sigstore.common.v1.X509CertificateChain x509_certificate_chain = 2 [(google.api.field_behavior) = REQUIRED]; dev.sigstore.common.v1.X509Certificate certificate = 5 [(google.api.field_behavior) = REQUIRED]; }PublicKeyIdentifieris the message type; the field ispublic_key, so protojson emitspublicKey. The X.509 example a few lines above already uses the field name (certificate, fromcertificate = 5) rather than the type name, so this example was the odd one out.It matters beyond tidiness: someone hand-assembling a bundle from this page puts the key hint under a name no verifier looks at, and the
contentoneof then has nothing set.One occurrence in the repo,
content/en/about/bundle.md:52. I left the##### Public Key Identifierheading alone, since that names the type and reads correctly as prose.