-
Notifications
You must be signed in to change notification settings - Fork 191
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
WinCrypt and Friends SSL Implementation #1135
Draft
Aidan63
wants to merge
54
commits into
HaxeFoundation:master
Choose a base branch
from
Aidan63:schannel
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
This file contains 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
Co-authored-by: Zeta <[email protected]>
Co-authored-by: Zeta <[email protected]>
Co-authored-by: Zeta <[email protected]>
Revert "try compiling mbedtls in its own files tag against a c std version" This reverts commit fe6ec81.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
(Builds on top of the mbedtls3 branch, hence the large diff)
This is an attempt at providing a SSL implementation using the build in Windows cryptographic libraries, WinCrypt, CNG (Cryptographic Next Generation), and SChannel. Benefits of this being,
With that all said there are some unknowns here, these APIs are much lower lever than mbedtls and example usage is very limited. There is also no definitive list of what key and cert formats are supported by these APIs and what haxe expects to be supported. These haxe APIs also seem to have very little to no use in some cases, so I've not got much to go on for whats actually expected.
Below are some general questions / points I'd like some help on.
I've added some new tests to this repo since the haxe test suite only has a hand full of very basic ssl api tests, might make more sense for them to be move to the haxe repo instead.
These APIs have no support for
RIPEMD160
, so this algorithm will never work.The cert tests I've added are failing on mbedtls! Tests like
cert.subject('O')
. Maybe these have been broken for a long time, the only use of them on github I can find is openfl (https://github.com/openfl/openfl/blob/b1bb7052f1a3d0403be6d79e4e9edd17e160cfb1/src/openfl/net/SecureSocket.hx#L166).What is supported with these
subject
andissuer
functions, just the short character codes or the long names as well?You can't load a DER encrypted private key as that function doesn't let you specify a password.
What is the certificate
add
andaddDER
supposed to do and be used for?You can go back to using the mbedtls implementation by using
HXCPP_USE_MBEDTLS
.