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

Implement FromDer trait and DerIterator type #139

Merged
merged 2 commits into from
Jul 28, 2023
Merged

Implement FromDer trait and DerIterator type #139

merged 2 commits into from
Jul 28, 2023

Conversation

djc
Copy link
Member

@djc djc commented Jul 26, 2023

Right now this is only a little bit more concise but I feel like it might help structure things going forward?

Needs a thorough audit for the correctness of consuming entire DER sequences, not sure we're entirely consistent (and have good coverage of) the read_all() aspect of things. (But I think this could help get that right in the future?)

@djc djc requested review from cpu and ctz July 26, 2023 21:50
@codecov
Copy link

codecov bot commented Jul 26, 2023

Codecov Report

Merging #139 (0c796ab) into main (55f7b5d) will decrease coverage by 0.32%.
The diff coverage is 100.00%.

❗ Current head 0c796ab differs from pull request most recent head 41c6d31. Consider uploading reports for the commit 41c6d31 to get more accurate results

@@            Coverage Diff             @@
##             main     #139      +/-   ##
==========================================
- Coverage   95.35%   95.04%   -0.32%     
==========================================
  Files          15       15              
  Lines        4007     3731     -276     
==========================================
- Hits         3821     3546     -275     
+ Misses        186      185       -1     
Files Changed Coverage Δ
src/verify_cert.rs 95.23% <ø> (ø)
src/cert.rs 96.66% <100.00%> (-0.14%) ⬇️
src/crl.rs 100.00% <100.00%> (+0.33%) ⬆️
src/der.rs 98.14% <100.00%> (+0.04%) ⬆️
src/signed_data.rs 100.00% <100.00%> (ø)
src/subject_name/verify.rs 96.56% <100.00%> (ø)

... and 3 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@djc djc force-pushed the der-traits branch 2 times, most recently from 10506cd to 0c796ab Compare July 26, 2023 21:56
Copy link
Member

@cpu cpu left a comment

Choose a reason for hiding this comment

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

This looks like a nice tidy-up to me, thanks @djc!

Tiny nit: maybe squash the 3rd commit into the 1st and switch the usages over to the new pattern in one fell swoop?

@djc
Copy link
Member Author

djc commented Jul 28, 2023

Needs a thorough audit for the correctness of consuming entire DER sequences, not sure we're entirely consistent (and have good coverage of) the read_all() aspect of things. (But I think this could help get that right in the future?)

I spent some time looking at this and I think it's now correct. But review on these aspects would be good!

Tiny nit: maybe squash the 3rd commit into the 1st and switch the usages over to the new pattern in one fell swoop?

Yup, good point -- done.

Copy link
Member

@ctz ctz left a comment

Choose a reason for hiding this comment

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

looks reasonable to me!

@djc djc added this pull request to the merge queue Jul 28, 2023
@djc
Copy link
Member Author

djc commented Jul 28, 2023

@cpu hope this doesn't cause too much thrashing in your open PRs!

Merged via the queue into main with commit 56c55c8 Jul 28, 2023
42 checks passed
@djc djc deleted the der-traits branch July 28, 2023 10:08
@cpu
Copy link
Member

cpu commented Jul 28, 2023

Nothing some git-fu won't solve :-)

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.

3 participants