]> granicus.if.org Git - apache/commitdiff
add configure checks for ssl functions:
authorDoug MacEachern <dougm@apache.org>
Wed, 27 Mar 2002 17:02:56 +0000 (17:02 +0000)
committerDoug MacEachern <dougm@apache.org>
Wed, 27 Mar 2002 17:02:56 +0000 (17:02 +0000)
-SSL_set_state: macro in OpenSSL, might be a function in a patched sslc
-SSL_set_cert_store: patch submitted to OpenSSL, might be applied to
OpenSSL or sslc

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@94223 13f79535-47bb-0310-9956-ffa450edef68

modules/ssl/config.m4
modules/ssl/ssl_engine_config.c
modules/ssl/ssl_engine_kernel.c
modules/ssl/ssl_toolkit_compat.h

index 3841cafd568eb6d5e059013b2ab04943b5853e6e..a73c85a00f7f2853a1dc539aec63008d0de6f2b7 100644 (file)
@@ -78,6 +78,8 @@ ssl_util_table.lo dnl
 dnl #  hook module into the Autoconf mechanism (--enable-ssl option)
 APACHE_MODULE(ssl, [SSL/TLS support (mod_ssl)], $ssl_objs, , no, [
     APACHE_CHECK_SSL_TOOLKIT
+    AC_CHECK_FUNCS(SSL_set_state)
+    AC_CHECK_FUNCS(SSL_set_cert_store)
 ])
 
 dnl #  end of module specific part
index 389ffda136cf7b9542b360d2fac86106ff21ad67..bde5b62214338aa48ab83db9dce4cd4813cce9f7 100644 (file)
@@ -665,6 +665,12 @@ const char *ssl_cmd_SSLCertificateChainFile(cmd_parms *cmd, void *ctx,
 #define NO_PER_DIR_SSL_CA \
     "Your ssl library does not have support for per-directory CA"
 
+#ifdef HAVE_SSL_SET_CERT_STORE
+#   define MODSSL_HAVE_SSL_SET_CERT_STORE 1
+#else
+#   define MODSSL_HAVE_SSL_SET_CERT_STORE 0
+#endif
+
 #define MODSSL_SET_CA(f) \
     if (cmd->path) \
         if (MODSSL_HAVE_SSL_SET_CERT_STORE) \
index 5e89e758e3cca8c3acaa6801d6fa89e121b2aae2..2f2f84dfa7aa149b60eb599ff6ef466ab2023513 100644 (file)
@@ -578,7 +578,7 @@ int ssl_hook_Access(request_rec *r)
      * used SSL_CTX_set_cert_store which is not thread safe.
      */
 
-#if MODSSL_HAVE_SSL_SET_CERT_STORE
+#ifdef HAVE_SSL_SET_CERT_STORE
     /*
      * check if per-dir and per-server config field are not the same.
      * if f is defined in per-dir and not defined in per-server
@@ -629,7 +629,7 @@ int ssl_hook_Access(request_rec *r)
                 "Changed client verification locations "
                 "will force renegotiation");
     }
-#endif /* MODSSL_HAVE_SSL_SET_CERT_STORE */
+#endif /* HAVE_SSL_SET_CERT_STORE */
 
     /* 
      * SSL renegotiations in conjunction with HTTP
index d5652a27331251d51ebac07a5fa64d7597663a66..6714857c40b612ba8bb84ef99c51e90100ac9abf 100644 (file)
@@ -78,9 +78,8 @@
 #define modssl_PEM_read_bio_PrivateKey(b, k, cb, arg) \
    PEM_read_bio_PrivateKey(b, k, cb)
 
-/* XXX: add configure check */
 #ifndef HAVE_SSL_SET_STATE
-#define SSL_set_state(ssl, state)
+#define SSL_set_state(ssl, state) /* XXX: should throw an error */
 #endif
 
 #define modssl_set_cipher_list(ssl, l) \