First call to SSL_CTX_new is failing on AL2023 (3.0.12) #23016
-
|
Hi, I'm trying to switch from OpenSSL 1.1.1v to 3.0.12. I'm using static OpenSSL through Boost.Asio. On Windows 10 (VS2019), Debian Bullseye (gcc 10.2.1), macOS everything is working fine. On Amazon Linux 2023 I've got this exception "context: unknown option (digital envelope routines) [asio.ssl:50331817]". After some debugging it seems that first call to SSL_CTX_new returns NULL. But all the following calls with the same parameter are succeeding. Is there some initialization that should be done before SSL_CTX_new that might be missing in Boost? |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 12 replies
-
|
This suggests a problem in your config file. The reason it is failing on the first call to What does your OpenSSL config file look like? Do you have a line starting with "alg_section ="? What ever it is set to (e.g. often something like "evp_properties" or similar), there should be a section corresponding to that name in the config file. What does that section contain? |
Beta Was this translation helpful? Give feedback.
-
|
I wonder if there are any vendor-specific patches applied over OpenSSL on Amazon Linux. You can try explicitly initializing the libssl library with OPENSSL_init_ssl() but it should not be necessary. |
Beta Was this translation helpful? Give feedback.
-
This was also an issue for me using a docker built, statically linked ffmpeg binary outside of it's container environment (alpine). Issue notied on Fedora 40 for the first time while testing ffprobe for available protocols and such. I got rid of it by adding the following line to
Which will ignore the specific redhat configuration - AND also any other config errors Having said that, does anyone see any potential serious issue that could result from disabling the config diagnostics? From where i stand, it's certainly very convenient and a 'solution' requiring very little effort which also seems to be permanent and could potentially apply to a broad range of other applications raising similar issues... i'm all ears about my 'hack' and how brilliant it isn't! Thanks! |
Beta Was this translation helpful? Give feedback.
-
|
It works for me to change too config_diagnostics = 1 on Fedora 41. |
Beta Was this translation helpful? Give feedback.
Setting the
OPENSSL_CONFenvironment variable to point to an alternative config file without the problematic line should fix it.