Skip to content

Commit e0be9fb

Browse files
committed
Merge r1926720, r1926722 from trunk:
* modules/ssl/ssl_private.h: For OpenSSL >= 3.5.0 drop $SSLKEYLOGFILE handling inside mod_ssl where OpenSSL is built to handle that internally in libssl. * modules/ssl/ssl_private.h: Fix logic in r1926720 HAVE_OPENSSL_KEYLOG macro, thanks to rpluem. Reviewed by: rpluem Submitted by: jorton Reviewed by: jorton, rpluem, ylavic Github: closes #538 git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.4.x@1927023 13f79535-47bb-0310-9956-ffa450edef68
1 parent 274a11c commit e0be9fb

File tree

2 files changed

+13
-2
lines changed

2 files changed

+13
-2
lines changed
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
*) mod_ssl: Drop $SSLKEYLOGFILE handling internally for OpenSSL 3.5
2+
builds which enable it in libssl natively. [Joe Orton]
3+

modules/ssl/ssl_private.h

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -290,8 +290,16 @@ void free_bio_methods(void);
290290
#define X509_get_notAfter X509_getm_notAfter
291291
#endif
292292

293-
#if OPENSSL_VERSION_NUMBER >= 0x10101000L && !defined(LIBRESSL_VERSION_NUMBER)
294-
#define HAVE_OPENSSL_KEYLOG
293+
/* The SSL_CTX_set_keylog_callback() API is present in 1.1.1+.
294+
*
295+
* OpenSSL 3.5+ also provides optional native handling of
296+
* $SSLKEYLOGFILE inside libssl, which duplicates the mod_ssl support.
297+
* The mod_ssl support is hence disabled for 3.5+, unless that OpenSSL
298+
* feature is itself disabled (and OPENSSL_NO_SSLKEYLOG is defined).
299+
*/
300+
#if OPENSSL_VERSION_NUMBER >= 0x10101000L && !defined(LIBRESSL_VERSION_NUMBER) \
301+
&& (OPENSSL_VERSION_NUMBER <= 0x30500000L || defined(OPENSSL_NO_SSLKEYLOG))
302+
#define HAVE_OPENSSL_KEYLOG
295303
#endif
296304

297305
#ifdef HAVE_FIPS

0 commit comments

Comments
 (0)