-
Notifications
You must be signed in to change notification settings - Fork 1k
Implementing missing macros to openssl compatibility layer #10520
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
Closed
Roy-Carter
wants to merge
11
commits into
wolfSSL:master
from
Roy-Carter:feature/extending_comp_layer
Closed
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
386dda0
Introduce missing functionality that was found in compatibility layer…
Roy-Carter 0de77c4
Refactor - Fix PR notes
Roy-Carter a35531e
Bugfix - fix tests failure
Roy-Carter fc60929
Fix SSL_set_ciphersuites test under NO_ERROR_STRINGS
julek-wolfssl 02ce4ef
Fix X509V3_ADD_* semantics and extension removal state
julek-wolfssl b340414
Keep new test comment within 80 columns
julek-wolfssl 60499d6
Record the point conversion form in EC_KEY_oct2key
julek-wolfssl 59993c9
Consume extKeyUsage object stacks in X509_add_ext
julek-wolfssl ab01395
X509_add1_ext_i2d: report NIDs with no presence tracking
julek-wolfssl 31e9207
X509_add1_ext_i2d: refuse an extension encoded under another NID
julek-wolfssl 6225adf
X509_add1_ext_i2d: validate an extKeyUsage stack before replacing
julek-wolfssl File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🟠 [Medium] wolfSSL_EC_KEY_oct2key does not record the point conversion form
OpenSSL's
EC_KEY_oct2key()saves the encoding form on the key (key->conv_form = (point_conversion_form_t)(buf[0] & ~0x01)), so that a lateri2o_ECPublicKey()/EC_KEY_key2buf()re-emits the same form. The wolfSSL implementation never toucheskey->form, so a compressed input silently round-trips back as uncompressed.Verified empirically on this branch:
This matters for applications that hash or compare the re-encoded public key (e.g. JWK/COSE key thumbprints, TLS raw public keys), because they will get a different byte string than OpenSSL would.
Fix: Call
wolfSSL_EC_KEY_set_conv_form(key, buf[0] & ~0x01)on success, and document the behaviour in the function's doxygen block.