You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by jo...@apache.org on 2004/04/15 21:41:39 UTC

cvs commit: httpd-2.0/modules/ssl ssl_engine_io.c

jorton      2004/04/15 12:41:39

  Modified:    .        Tag: APACHE_2_0_BRANCH CHANGES STATUS
               modules/ssl Tag: APACHE_2_0_BRANCH ssl_engine_io.c
  Log:
  * modules/ssl/ssl_engine_io.c (ssl_io_filter_cleanup): Don't try and
  send an SSL shutdown from a pool cleanup.
  
  PR: 27945
  Reviewed by: Jeff Trawick, Madhusudan Mathihalli
  
  Revision  Changes    Path
  No                   revision
  No                   revision
  1.988.2.266 +3 -0      httpd-2.0/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/CHANGES,v
  retrieving revision 1.988.2.265
  retrieving revision 1.988.2.266
  diff -w -d -u -r1.988.2.265 -r1.988.2.266
  --- CHANGES	12 Apr 2004 17:38:37 -0000	1.988.2.265
  +++ CHANGES	15 Apr 2004 19:41:37 -0000	1.988.2.266
  @@ -1,5 +1,8 @@
   Changes with Apache 2.0.50
   
  +  *) mod_ssl: Fix potential segfaults when performing SSL shutdown from
  +     a pool cleanup.  PR 27945.  [Joe Orton]
  +
     *) Add forensic logging module (mod_log_forensic).
        [Ben Laurie]
   
  
  
  
  1.751.2.818 +1 -5      httpd-2.0/STATUS
  
  Index: STATUS
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/STATUS,v
  retrieving revision 1.751.2.817
  retrieving revision 1.751.2.818
  diff -w -d -u -r1.751.2.817 -r1.751.2.818
  --- STATUS	14 Apr 2004 14:45:28 -0000	1.751.2.817
  +++ STATUS	15 Apr 2004 19:41:38 -0000	1.751.2.818
  @@ -142,10 +142,6 @@
            modules/experimental/util_ldap.c: r1.22, r1.24
          +1: bnicholes, minfrin
       
  -    *) mod_ssl: Fix segfaults when doing shutdown from a cleanup.
  -       http://cvs.apache.org/viewcvs.cgi/httpd-2.0/modules/ssl/ssl_engine_io.c?r1=1.121&r2=1.122
  -       +1: jorton, trawick, madhum
  -
       *) (re-)add support for RewriteRules in <Proxy> containers. PR 27985
            modules/mappers/mod_rewrite.c: r1.254
          +1: nd, trawick
  
  
  
  No                   revision
  No                   revision
  1.100.2.14 +11 -13    httpd-2.0/modules/ssl/ssl_engine_io.c
  
  Index: ssl_engine_io.c
  ===================================================================
  RCS file: /home/cvs/httpd-2.0/modules/ssl/ssl_engine_io.c,v
  retrieving revision 1.100.2.13
  retrieving revision 1.100.2.14
  diff -w -d -u -r1.100.2.13 -r1.100.2.14
  --- ssl_engine_io.c	8 Mar 2004 17:40:36 -0000	1.100.2.13
  +++ ssl_engine_io.c	15 Apr 2004 19:41:39 -0000	1.100.2.14
  @@ -983,22 +983,20 @@
   
   static apr_status_t ssl_io_filter_cleanup(void *data)
   {
  -    apr_status_t ret;
  -    ssl_filter_ctx_t *filter_ctx = (ssl_filter_ctx_t *)data;
  -    conn_rec *c;
  +    ssl_filter_ctx_t *filter_ctx = data;
   
  -    if (!filter_ctx->pssl) {
  -        /* already been shutdown */
  -        return APR_SUCCESS;
  -    }
  +    if (filter_ctx->pssl) {
  +        conn_rec *c = (conn_rec *)SSL_get_app_data(filter_ctx->pssl);
  +        SSLConnRec *sslconn = myConnConfig(c);
   
  -    c = (conn_rec *)SSL_get_app_data(filter_ctx->pssl);
  -    if ((ret = ssl_filter_io_shutdown(filter_ctx, c, 0)) != APR_SUCCESS) {
  -        ap_log_error(APLOG_MARK, APLOG_INFO, ret, NULL,
  -                     "SSL filter error shutting down I/O");
  +        ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL,
  +                     "SSL connection destroyed without being closed");
  +
  +        SSL_free(filter_ctx->pssl);
  +        sslconn->ssl = filter_ctx->pssl = NULL;
       }
   
  -    return ret;
  +    return APR_SUCCESS;
   }
   
   /*