summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikita Popov <nikita.ppv@gmail.com>2020-11-30 15:17:27 +0100
committerNikita Popov <nikita.ppv@gmail.com>2020-11-30 15:17:27 +0100
commit32cd5a1bc8616435e50445ec43e157ca4bb10e4c (patch)
tree5d6f0a7d63fdd66bc7a33daab716f7a57143933c
parent0076b47326e53d98b5df56c5f970b2b5cc3d9b6d (diff)
parentecee3f1209a7c0ac9f99c7f640b2f5df56656e58 (diff)
downloadphp-git-32cd5a1bc8616435e50445ec43e157ca4bb10e4c.tar.gz
Merge branch 'PHP-7.4' into PHP-8.0
* PHP-7.4: Next attempt to fix bug #80368
-rw-r--r--ext/openssl/openssl.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c
index 60556d84ae..e21c3aacb3 100644
--- a/ext/openssl/openssl.c
+++ b/ext/openssl/openssl.c
@@ -6901,8 +6901,9 @@ static void php_openssl_load_cipher_mode(struct php_openssl_cipher_mode *mode, c
int cipher_mode = EVP_CIPHER_mode(cipher_type);
memset(mode, 0, sizeof(struct php_openssl_cipher_mode));
switch (cipher_mode) {
-#if OPENSSL_VERSION_NUMBER >= 0x10100000L
- /* Note: While OpenSSL 1.1 supports OCB mode, LibreSSL does not support it. */
+#ifdef EVP_CIPH_OCB_MODE
+ /* Since OpenSSL 1.1, all AEAD ciphers use a common framework. We check for
+ * EVP_CIPH_OCB_MODE, because LibreSSL does not support it. */
case EVP_CIPH_GCM_MODE:
case EVP_CIPH_OCB_MODE:
case EVP_CIPH_CCM_MODE: