httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From do...@apache.org
Subject cvs commit: httpd-2.0/modules/ssl ssl_engine_init.c
Date Thu, 28 Mar 2002 02:40:01 GMT
dougm       02/03/27 18:40:01

  Modified:    modules/ssl ssl_engine_init.c
  Log:
  move context callback setting to ssl_init_ctx_callbacks function
  
  Revision  Changes    Path
  1.78      +19 -11    httpd-2.0/modules/ssl/ssl_engine_init.c
  
  Index: ssl_engine_init.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/ssl/ssl_engine_init.c,v
  retrieving revision 1.77
  retrieving revision 1.78
  diff -u -r1.77 -r1.78
  --- ssl_engine_init.c	28 Mar 2002 02:36:05 -0000	1.77
  +++ ssl_engine_init.c	28 Mar 2002 02:40:01 -0000	1.78
  @@ -478,6 +478,22 @@
       SSL_CTX_sess_set_remove_cb(ctx, ssl_callback_DelSessionCacheEntry);
   }
   
  +static void ssl_init_ctx_callbacks(server_rec *s,
  +                                   apr_pool_t *p,
  +                                   apr_pool_t *ptemp,
  +                                   SSLSrvConfigRec *sc)
  +{
  +    SSL_CTX *ctx = sc->pSSLCtx;
  +
  +    SSL_CTX_set_tmp_rsa_callback(ctx, ssl_callback_TmpRSA);
  +    SSL_CTX_set_tmp_dh_callback(ctx,  ssl_callback_TmpDH);
  +
  +    if (sc->nLogLevel >= SSL_LOG_INFO) {
  +        /* this callback only logs if SSLLogLevel >= info */
  +        SSL_CTX_set_info_callback(ctx, ssl_callback_LogTracingState);
  +    }
  +}
  +
   static void ssl_init_verify(server_rec *s,
                               apr_pool_t *p,
                               apr_pool_t *ptemp,
  @@ -855,14 +871,14 @@
                                 apr_pool_t *ptemp,
                                 SSLSrvConfigRec *sc)
   {
  -    SSL_CTX *ctx;
  -
       ssl_init_check_server(s, p, ptemp, sc);
   
  -    ctx = ssl_init_ctx(s, p, ptemp, sc);
  +    ssl_init_ctx(s, p, ptemp, sc);
   
       ssl_init_session_cache_ctx(s, p, ptemp, sc);
   
  +    ssl_init_ctx_callbacks(s, p, ptemp, sc);
  +
       ssl_init_verify(s, p, ptemp, sc);
   
       ssl_init_cipher_suite(s, p, ptemp, sc);
  @@ -870,14 +886,6 @@
       ssl_init_crl(s, p, ptemp, sc);
   
       ssl_init_cert_chain(s, p, ptemp, sc);
  -
  -    SSL_CTX_set_tmp_rsa_callback(ctx, ssl_callback_TmpRSA);
  -    SSL_CTX_set_tmp_dh_callback(ctx,  ssl_callback_TmpDH);
  -
  -    if (sc->nLogLevel >= SSL_LOG_INFO) {
  -        /* this callback only logs if SSLLogLevel >= info */
  -        SSL_CTX_set_info_callback(ctx, ssl_callback_LogTracingState);
  -    }
   
       ssl_init_server_certs(s, p, ptemp, sc);
   }
  
  
  

Mime
View raw message