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

Add more complex TUF tests #4003

Merged
merged 1 commit into from
Jan 9, 2025
Merged

Conversation

cmurphy
Copy link
Contributor

@cmurphy cmurphy commented Jan 8, 2025

Add tests for invalid keys, custom metadata, and TSA verification.

These tests do not test the signing flow for when Fulcio issues a detached SCT, which can be affected by the TUF client, because the ephemral CA Fulcio backend cannot issue detached SCTs.

Summary

Release Note

Documentation

Add tests for invalid keys, custom metadata, and TSA verification.

These tests do not test the signing flow for when Fulcio issues a
detached SCT, which can be affected by the TUF client, because the
ephemral CA Fulcio backend cannot issue detached SCTs.

Signed-off-by: Colleen Murphy <[email protected]>
Copy link

codecov bot commented Jan 8, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 36.51%. Comparing base (2ef6022) to head (5c9605c).
Report is 274 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4003      +/-   ##
==========================================
- Coverage   40.10%   36.51%   -3.59%     
==========================================
  Files         155      209      +54     
  Lines       10044    13359    +3315     
==========================================
+ Hits         4028     4878     +850     
- Misses       5530     7860    +2330     
- Partials      486      621     +135     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Member

@cpanato cpanato left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cool

thanks!

@cmurphy cmurphy requested a review from jku January 8, 2025 16:56
Copy link
Contributor

@haydentherapper haydentherapper left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work on this!

Copy link
Member

@jku jku left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me, cases look reasonable.

cosign shouldn't really test tuf internals of course... but since the client does not yet use trusted_root.json and needs to do this meddling in the TUF internal, the test makes sense as well (and should translate to similar simpler tests in the future when we can just test the trusted_root.json parsing)

@haydentherapper haydentherapper merged commit 342f8d8 into sigstore:main Jan 9, 2025
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants