Commit b4db59ba authored by Georg Richter's avatar Georg Richter Committed by Sergei Golubchik

MDEV-15596 10.2 doesn't work with openssl 1.1.1

parent 1db1340c
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
#define HAVE_OPENSSL11 1 #define HAVE_OPENSSL11 1
#define SSL_LIBRARY OpenSSL_version(OPENSSL_VERSION) #define SSL_LIBRARY OpenSSL_version(OPENSSL_VERSION)
#define ERR_remove_state(X) ERR_clear_error() #define ERR_remove_state(X) ERR_clear_error()
#define EVP_CIPHER_CTX_SIZE 168 #define EVP_CIPHER_CTX_SIZE 176
#define EVP_MD_CTX_SIZE 48 #define EVP_MD_CTX_SIZE 48
#undef EVP_MD_CTX_init #undef EVP_MD_CTX_init
#define EVP_MD_CTX_init(X) do { bzero((X), EVP_MD_CTX_SIZE); EVP_MD_CTX_reset(X); } while(0) #define EVP_MD_CTX_init(X) do { bzero((X), EVP_MD_CTX_SIZE); EVP_MD_CTX_reset(X); } while(0)
...@@ -77,6 +77,10 @@ ...@@ -77,6 +77,10 @@
#define X509_get0_notAfter(X) X509_get_notAfter(X) #define X509_get0_notAfter(X) X509_get_notAfter(X)
#endif #endif
#ifndef TLS1_3_VERSION
#define SSL_CTX_set_ciphersuites(X,Y) 0
#endif
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif /* __cplusplus */ #endif /* __cplusplus */
......
...@@ -211,6 +211,7 @@ new_VioSSLFd(const char *key_file, const char *cert_file, ...@@ -211,6 +211,7 @@ new_VioSSLFd(const char *key_file, const char *cert_file,
none of the provided ciphers could be selected none of the provided ciphers could be selected
*/ */
if (cipher && if (cipher &&
SSL_CTX_set_ciphersuites(ssl_fd->ssl_context, cipher) == 0 &&
SSL_CTX_set_cipher_list(ssl_fd->ssl_context, cipher) == 0) SSL_CTX_set_cipher_list(ssl_fd->ssl_context, cipher) == 0)
{ {
*error= SSL_INITERR_CIPHERS; *error= SSL_INITERR_CIPHERS;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment