-
-
Notifications
You must be signed in to change notification settings - Fork 71
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
openssl 3.0 - how to enable legacy provider? #60
Comments
Okay, just added some debug prints and apparently |
Figured out two things: A) OSSL_PROVIDER_available might be broken on Ubuntu 22.04, as it returns 0 even though the legacy module is actually available. B) According to OpenSSL documentation, as soon as you load a provider, it will no longer auto-load the default providers, so you'd need to first load the "legacy", then the "default" provider. Maybe the code can be modded so it doesn't use the "available" function at all and just tries to load the legacy module and sees if it works? |
Sorry for the "comment spam": Looks like OSSL_PROVIDER_available does not indicate whether a provider can loaded, but rather whether it is currently loaded. So instead of first checking for availability, you need to try and load it immediately, then afterwards check if it's available. I'll be creating a PR. |
I updated my project to use oscrypto 1.3.0 to support Ubuntu 22.04 with Openssl 3, but I'm running into an issue.
If I'm reading the commit message of 5ae0e79 correctly, then oscrypto should support the legacy mode of openssl. However, my application fails when calling
parse_pkcs12
, and raises an exception inrc2_cbc_pkcs5_decrypt
with the message "OpenSSL has been compiled without RC2 support".Is there anything I can do from within Python / with oscrypto to get around that and have it still use RC2, or can I somehow enable this RC2 support in OpenSSL?
I believe applications do need to actively request this legacy provider, does oscrypto do that?
Looking at this code in _libcrypto.py:
this might already be implemented if I'm reading this correctly, but why doesn't it work then?
Can I somehow test if Ubuntu 22.04 actually ships completely without this legacy module?
The text was updated successfully, but these errors were encountered: