-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
add modussl_mbedtls.c methods and exceptions. esp32/unix #5436
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
Conversation
Interesting addition / fix! |
@tve I can understand that my PR is not really important for micropython unix port. I had done these changes in order to build my own http library that works well in china (TCP and SSL are definitely not stable here if I try to ping a server outside of the GFW). I also don't like the idea of using Since mbedTLS makes the distinction between Sorry that I couldn't do that for axTLS as well. |
Related #5840 |
@dpgeorge should I remove this merge request? |
Not at this stage, I think it's a valid alternative to consider for non-blocking SSL. |
_stage: Fix handling of scaled display in the stage library
Non-blocking SSL sockets have been implemented in a different way in ed58d6e |
See also related commit ef71028 |
Changes
This pull requests adds:
methods to ussl (mbedtls version only) plus few exceptions.
The goal is to fully support non-blocking ssl sockets and reduce the number of call to poll by throwing the exact I/O error like
SSL_WANT_READ
orSSL_WANT_WRITE
. the user has now the possibility to calldo_handshake()
later ifussl.wrap_socket
was set withdo_handshake = False
Tests
successfully tested on micropython/ports/esp-32 (esp-ifd rev 6ccb4cf) and micropython/ports/unix
Example