Skip to content

Back propagate errors from OpenSSL#23

Merged
maxtropets merged 1 commit intomainfrom
f/err-handling
Mar 24, 2026
Merged

Back propagate errors from OpenSSL#23
maxtropets merged 1 commit intomainfrom
f/err-handling

Conversation

@maxtropets
Copy link
Copy Markdown
Owner

No description provided.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR improves diagnostics by propagating human-readable OpenSSL error-queue details through signing, verification, and key (de)serialization paths, and updates/adds tests to assert on those error strings.

Changes:

  • Add ossl_err_string() helper and include OpenSSL error details in many Err(String) returns across wrappers/sign/verify.
  • Update COSE, sign, verify, and key import tests to assert on specific propagated error messages/details.
  • Refine error messages to include the OpenSSL function name and return code.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 6 comments.

File Description
src/verify.rs Adds OpenSSL error-queue detail to verify failures and introduces verify behavior tests.
src/sign.rs Adds OpenSSL error-queue detail to signing failures and introduces sign behavior tests.
src/ossl_wrappers.rs Introduces ossl_err_string() and threads OpenSSL error detail through key/context/ecdsa conversion errors; expands tests.
src/cose.rs Tightens negative tests to assert exact error strings and adds error-propagation tests through COSE APIs.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/ossl_wrappers.rs
Comment thread src/ossl_wrappers.rs
Comment thread src/ossl_wrappers.rs Outdated
Comment thread src/ossl_wrappers.rs Outdated
Comment thread src/ossl_wrappers.rs
Comment thread src/ossl_wrappers.rs
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/ossl_wrappers.rs
Comment thread src/ossl_wrappers.rs
@maxtropets maxtropets merged commit b55095a into main Mar 24, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants