-
Notifications
You must be signed in to change notification settings - Fork 556
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
Print message when verifying with old TUF targets #1468
Conversation
Typical verification used VerifyBundle, which called GetRekorKeys, which fetches keys from the TUF repo. If the bundle was not present or for a specific error when a duplicate log entry was present, then the tlog entry would be verified using a public key fetched from Rekor's API. This key was not verified using TUF metadata. This change simply removes the API call and uses Rekor public keys from the TUF repo. Tested locally by not including the Rekor bundle in the OCI signature, which will hit the code path to fetch the entry from the log. Signed-off-by: Hayden Blauzvern <hblauzvern@google.com>
This adds console messages when the TUF metadata used for Rekor or the CTFE key is marked as expired. I haven't added a log message for Fulcio yet. The way that certificates are verified is different. Instead of multiple verifications where we can easily determine which key successfully verified an object, the x509 library uses a CertPool and returns a valid chain. I'll need to plumb through the TUF information. Signed-off-by: Hayden Blauzvern <hblauzvern@google.com>
The UX here is fine, is there any way we could make this work for machine readable output too? Maybe include the TUF root we verified against? |
I'll take a look at piping some information to stdout. Is there any existing format for machine readable output? Just print JSON? |
This can come in a separate PR - but yeah it's typically just when we do --format=json. The basic idea is just that if we feel information is important enough to display to a person, it probably makes sense to make it parseable in a script too. |
* Verify tlog entries using the Rekor public keys from TUF Typical verification used VerifyBundle, which called GetRekorKeys, which fetches keys from the TUF repo. If the bundle was not present or for a specific error when a duplicate log entry was present, then the tlog entry would be verified using a public key fetched from Rekor's API. This key was not verified using TUF metadata. This change simply removes the API call and uses Rekor public keys from the TUF repo. Tested locally by not including the Rekor bundle in the OCI signature, which will hit the code path to fetch the entry from the log. Signed-off-by: Hayden Blauzvern <hblauzvern@google.com> * Print message when verifying with old TUF targets This adds console messages when the TUF metadata used for Rekor or the CTFE key is marked as expired. I haven't added a log message for Fulcio yet. The way that certificates are verified is different. Instead of multiple verifications where we can easily determine which key successfully verified an object, the x509 library uses a CertPool and returns a valid chain. I'll need to plumb through the TUF information. Signed-off-by: Hayden Blauzvern <hblauzvern@google.com>
* Verify tlog entries using the Rekor public keys from TUF Typical verification used VerifyBundle, which called GetRekorKeys, which fetches keys from the TUF repo. If the bundle was not present or for a specific error when a duplicate log entry was present, then the tlog entry would be verified using a public key fetched from Rekor's API. This key was not verified using TUF metadata. This change simply removes the API call and uses Rekor public keys from the TUF repo. Tested locally by not including the Rekor bundle in the OCI signature, which will hit the code path to fetch the entry from the log. Signed-off-by: Hayden Blauzvern <hblauzvern@google.com> * Print message when verifying with old TUF targets This adds console messages when the TUF metadata used for Rekor or the CTFE key is marked as expired. I haven't added a log message for Fulcio yet. The way that certificates are verified is different. Instead of multiple verifications where we can easily determine which key successfully verified an object, the x509 library uses a CertPool and returns a valid chain. I'll need to plumb through the TUF information. Signed-off-by: Hayden Blauzvern <hblauzvern@google.com>
Summary
This adds console messages when the TUF metadata
used for Rekor or the CTFE key is marked as expired.
I haven't added a log message for Fulcio yet. The way
that certificates are verified is different. Instead of
multiple verifications where we can easily determine
which key successfully verified an object, the x509
library uses a CertPool and returns a valid chain.
I'll need to plumb through the TUF information.
Ticket Link
Fixes
Release Note