]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
* Check for correct OpenSSL version for mod_ssl_ct
authorRuediger Pluem <rpluem@apache.org>
Fri, 5 Jul 2024 14:50:24 +0000 (14:50 +0000)
committerRuediger Pluem <rpluem@apache.org>
Fri, 5 Jul 2024 14:50:24 +0000 (14:50 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1918935 13f79535-47bb-0310-9956-ffa450edef68

modules/ssl/config.m4

index 8b756b011c705571d34abff6151fa78f94e6aabd..687368aaef02a2cb16e4d1128e29bd8d0771bbcb 100644 (file)
@@ -54,7 +54,17 @@ APR_ADDTO(INCLUDES, [-I\$(top_srcdir)/$modpath_current])
 
 ssl_ct_objs="mod_ssl_ct.lo ssl_ct_log_config.lo ssl_ct_sct.lo ssl_ct_util.lo"
 APACHE_MODULE(ssl_ct, [Support for Certificate Transparency (RFC 6962)], $ssl_ct_objs, , no, [
-    dnl TODO: Check for OpenSSL >= 1.0.2
+    AC_MSG_CHECKING([for OpenSSL version >= 1.0.2])
+    AC_TRY_COMPILE([#include <openssl/opensslv.h>],[
+#if !defined(OPENSSL_VERSION_NUMBER)
+#error "Missing OpenSSL version"
+#endif
+#if OPENSSL_VERSION_NUMBER < 0x10002003L
+#error "Unsupported OpenSSL version " OPENSSL_VERSION_TEXT
+#endif],
+      [AC_MSG_RESULT(yes)],
+      [AC_MSG_ERROR([mod_ssl_ct requires OpenSSL 1.0.2-beta3 or later.])])
+
     if test "$enable_ssl" = "no"; then
         AC_MSG_ERROR([mod_ssl_ct is dependent on mod_ssl, which is not enabled.])
     fi