From: Graham Leggett Date: Sun, 6 Apr 2008 14:23:35 +0000 (+0000) Subject: mod_session_crypto: Initialise SSL in the post config hook. X-Git-Tag: 2.3.0~800 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f2125f46ecdb809e05c31b7d7090275437bd1bd5;p=thirdparty%2Fapache%2Fhttpd.git mod_session_crypto: Initialise SSL in the post config hook. git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@645244 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/CHANGES b/CHANGES index 87dc3cfeb09..2a0348152e2 100644 --- a/CHANGES +++ b/CHANGES @@ -2,6 +2,9 @@ Changes with Apache 2.3.0 [ When backported to 2.2.x, remove entry from this file ] + *) mod_session_crypto: Initialise SSL in the post config hook. + [Ruediger Pluem, Graham Leggett] + *) mod_session_dbd: Add a session implementation capable of storing session information in a SQL database via the dbd interface. Useful for sites where session privacy is important. [Graham Leggett] diff --git a/modules/session/mod_session_crypto.c b/modules/session/mod_session_crypto.c index 80f5b62de86..38ec39f213e 100644 --- a/modules/session/mod_session_crypto.c +++ b/modules/session/mod_session_crypto.c @@ -316,6 +316,15 @@ AP_DECLARE(int) ap_session_crypto_decode(request_rec * r, session_rec * z) } +/** + * Initialise the SSL in the post_config hook. + */ +AP_DECLARE(int) ap_session_crypto_init(apr_pool_t *p, apr_pool_t *plog, + apr_pool_t *ptemp, server_rec *s) +{ + apr_ssl_init(); + return OK; +} @@ -328,9 +337,6 @@ static void *create_session_crypto_dir_config(apr_pool_t * p, char *dummy) new->cipher = DEFAULT_CIPHER; new->digest = DEFAULT_DIGEST; - /* initialise SSL */ - apr_ssl_init(); - return (void *) new; } @@ -453,6 +459,7 @@ static void register_hooks(apr_pool_t * p) { ap_hook_session_encode(ap_session_crypto_encode, NULL, NULL, APR_HOOK_LAST); ap_hook_session_decode(ap_session_crypto_decode, NULL, NULL, APR_HOOK_FIRST); + ap_hook_post_config(ap_session_crypto_init, NULL, NULL, APR_HOOK_FIRST); } module AP_MODULE_DECLARE_DATA session_crypto_module =