Browse Source

Fix SSL initialization for OpenSSL >= 1.1.

The first argument of the OPENSSL_init_ssl and OPENSSL_init_crypto
functions must be a 64-bit int, not a 32-bit int, as this caused
unpredictable OpenSSL behavior.

This resolves bug 3024.

Signed-off-by: Slávek Banko <slavek.banko@axis.cz>
pull/50/head
Slávek Banko 1 month ago
parent
commit
a2ad929640
Signed by: Slávek Banko <slavek.banko@axis.cz> GPG Key ID: 608F5293A04BE668
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      tdeio/kssl/kopenssl.cc

+ 2
- 2
tdeio/kssl/kopenssl.cc View File

@@ -661,9 +661,9 @@ TDEConfig *cfg;
if (x) {
// OpenSSL >= 1.1
if (_cryptoLib) {
((int (*)(unsigned long, void*))x)(0, NULL);
((int (*)(unsigned long long, void*))x)(0, NULL);
x = GET_CRYPTOLIB_SYMBOL("OPENSSL_init_crypto");
if (x) ((int (*)(unsigned long, void*))x)(OPENSSL_INIT_ADD_ALL_CIPHERS
if (x) ((int (*)(unsigned long long, void*))x)(OPENSSL_INIT_ADD_ALL_CIPHERS
| OPENSSL_INIT_ADD_ALL_DIGESTS
| OPENSSL_INIT_LOAD_CONFIG,
NULL);

Loading…
Cancel
Save