Skip to content

Commit

Permalink
Fixed bug #80368
Browse files Browse the repository at this point in the history
We assume that usually LibreSSL supports everything OpenSSL 1.1 does.
In this instance, this is not the case.
  • Loading branch information
nikic committed Nov 27, 2020
1 parent 5240f83 commit 0f579fd
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
4 changes: 4 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ PHP NEWS
- Intl:
. Fixed bug #80425 (MessageFormatAdapter::getArgTypeList redefined). (Nikita)

- OpenSSL:
. Fixed bug #80368 (OpenSSL extension fails to build against LibreSSL due to
lack of OCB support). (Nikita)

- Standard:
. Fixed bug #80366 (Return Value of zend_fstat() not Checked). (sagpant, cmb)
. Fixed bug #80411 (References to null-serialized object break serialize()).
Expand Down
3 changes: 2 additions & 1 deletion ext/openssl/openssl.c
Original file line number Diff line number Diff line change
Expand Up @@ -6496,7 +6496,8 @@ 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 PHP_OPENSSL_API_VERSION >= 0x10100
#if OPENSSL_VERSION_NUMBER >= 0x10100000L
/* Note: While OpenSSL 1.1 supports OCB mode, LibreSSL does not support it. */
case EVP_CIPH_GCM_MODE:
case EVP_CIPH_OCB_MODE:
case EVP_CIPH_CCM_MODE:
Expand Down

0 comments on commit 0f579fd

Please sign in to comment.