OpenSSL: bump the minimum supported version to 1.1.1

We don't support 1.0 any more, and 1.1.0 has reached EOL.
Bump to 1.1.1 so we can freely use its APIs.

[ChangeLog][QtNetwork][SSL] The minimum required version
of OpenSSL is now 1.1.1.

Change-Id: I5cfb6672fadfa48aedaefbcd6a954aa9eb85bfa5
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
This commit is contained in:
Giuseppe D'Angelo 2020-03-19 21:18:19 +01:00
parent aa5855847c
commit d41d8297c8
2 changed files with 9 additions and 3 deletions

View File

@ -61,11 +61,11 @@
"export": "openssl",
"test": {
"tail": [
"#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER-0 < 0x10100000L",
"# error OpenSSL >= 1.1.0 is required",
"#if !defined(OPENSSL_VERSION_NUMBER) || OPENSSL_VERSION_NUMBER-0 < 0x10101000L",
"# error OpenSSL >= 1.1.1 is required",
"#endif",
"#if !defined(OPENSSL_NO_EC) && !defined(SSL_CTRL_SET_CURVES)",
"# error OpenSSL was reported as >= 1.1.0 but is missing required features, possibly it's libressl which is unsupported",
"# error OpenSSL was reported as >= 1.1.1 but is missing required features, possibly it's libressl which is unsupported",
"#endif"
]
},

View File

@ -1942,6 +1942,12 @@ bool QSslSocketPrivate::ensureLibraryLoaded()
// Initialize OpenSSL.
if (q_OPENSSL_init_ssl(0, nullptr) != 1)
return false;
if (q_OpenSSL_version_num() < 0x10101000L) {
qCWarning(lcSsl, "QSslSocket: OpenSSL >= 1.1.1 is required; %s was found instead", q_OpenSSL_version(OPENSSL_VERSION));
return false;
}
q_SSL_load_error_strings();
q_OpenSSL_add_all_algorithms();