httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 20462] - Potential fix in ssl_engine_init.c-->stopping or restarting Apache 2.0.46 under Windows causes a crash if a module logs in its cleanup routines
Date Mon, 10 May 2004 19:47:59 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=20462>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=20462

Potential fix in ssl_engine_init.c-->stopping or restarting Apache 2.0.46 under Windows
causes a crash if a module logs in its cleanup routines

zvieger@textfactory.co.at changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |WORKSFORME



------- Additional Comments From zvieger@textfactory.co.at  2004-05-10 19:47 -------
Those lines (ssl_callback_DelSessionCacheEntry) are meant as guard - but the 
condition never comes true when Apache is terminated with SSL-Childs still 
connected.



    if (!(s = (server_rec *)SSL_CTX_get_app_data(ctx))) {
        return; /* on server shutdown Apache is already gone */
    }

It runs into logging to an invalid filehandle. Dirty fix in apr_file_write.

    if (thefile->filehand == INVALID_HANDLE_VALUE)
	{
		return APR_SUCCESS;
	}

The problem is actually a race condition in libeay32::doall_util_fn
    a=lh->b[i]

left side ! NULL and right side NULL in while loop - uups

I lack the literacy to fix it prooperly


See stack trace (W2K/SP4/Intel8.0 with VC71 integration 2.0.49:

 	libapr.dll!apr_thread_mutex_lock(apr_thread_mutex_t * 
mutex=0x00468e28)  Zeile 83 + 0x11	C
 	libapr.dll!apr_file_write(apr_file_t * thefile=0x00468db0, const void * 
buf=0x0006b91c, unsigned int * nbytes=0x0006b8f4)  Zeile 279	C
 	libapr.dll!apr_file_puts(const char * str=0x0006b91c, apr_file_t * 
thefile=0x00468db0)  Zeile 403 + 0x1c	C
 	libhttpd.dll!log_error_core(const char * const file=0x6fd2673c, int 
line=0x00000062, int level=0x00000004, int status=0x000afc86, const server_rec 
* s=0x004c1640, const request_rec * r=0x00000000, apr_pool_t * pool=0x00000000, 
const char * const fmt=0x6fd267d0, char * args=0x0006fcc4)  Zeile 534	C
 	libhttpd.dll!ap_log_error(const char * const file=0x6fd2673c, int 
line=0x00000062, int level=0x00000004, int status=0x000afc86, const server_rec 
* s=0x004c1640, const char * const fmt=0x6fd267d0)  Zeile 552 + 0x42	C
 	mod_ssl.so!ssl_mutex_on(server_rec * s=0x004c1640)  Zeile 98 + 0x2
	C
 	mod_ssl.so!ssl_scache_dbm_remove(server_rec * s=0x004c1640, unsigned 
char * id=0x005259c0, int idlen=0x00000020)  Zeile 273 + 0xc	C
 	mod_ssl.so!ssl_scache_remove(server_rec * s=0x004c1640, unsigned char * 
id=0x005259c0, int idlen=0x00000020)  Zeile 120 + 0x1c	C
 	mod_ssl.so!ssl_callback_DelSessionCacheEntry(ssl_ctx_st * 
ctx=0x004fd198, ssl_session_st * session=0x00525978)  Zeile 1708 + 0x1c	C
 	ssleay32.dll!timeout(ssl_session_st * s=0x00525978, timeout_param_st * 
p=0x0006fda8)  Zeile 663 + 0x1c	C
 	ssleay32.dll!timeout_LHASH_DOALL_ARG(const void * arg1=0x00525978, void 
* arg2=0x0006fda8)  Zeile 668 + 0x3e	C
>	libeay32.dll!doall_util_fn(lhash_st * lh=0x004fd338, int 
use_arg=0x00000001, void (const void *, const void *)* func=0x00000000, void 
(const void *, void *, const void *, void *)* func_arg=0x00b9d046, void * 
arg=0x0006fda8)  Zeile 287 + 0x17	C
 	libeay32.dll!lh_doall_arg(lhash_st * lh=0x004fd338, void (const void *, 
void *, const void *, void *)* func=0x00b9d046, void * arg=0x0006fda8)  Zeile 
302 + 0x2c	C
 	ssleay32.dll!SSL_CTX_flush_sessions(ssl_ctx_st * s=0x004fd198, long 
t=0x00000000)  Zeile 682 + 0x1d	C
 	ssleay32.dll!SSL_CTX_free(ssl_ctx_st * a=0x004fd198)  Zeile 1435 + 0x16
	C
 	mod_ssl.so!ssl_init_ctx_cleanup(modssl_ctx_t * mctx=0x004c2e48)  Zeile 
1171 + 0x19	C
 	mod_ssl.so!ssl_init_ctx_cleanup_server(modssl_ctx_t * mctx=0x004c2e48)  
Zeile 1187 + 0xc	C
 	mod_ssl.so!ssl_init_ModuleKill(void * data=0x0043c180)  Zeile 1226 + 0xf
	C
 	libapr.dll!run_cleanups(cleanup_t * * cref=0x0043a2f8)  Zeile 1957 + 
0x12	C
 	libapr.dll!apr_pool_destroy(apr_pool_t * pool=0x0043a2e8)  Zeile 734 + 
0xf	C
 	libapr.dll!apr_pool_destroy(apr_pool_t * pool=0x004382b8)  Zeile 727
	C
 	Apache.exe!destroy_and_exit_process(process_rec * process=0x00438348, 
int process_exit_value=0x00000000)  Zeile 209	C
 	Apache.exe!main(int argc=0x00000005, const char * const * 
argv=0x00437d00)  Zeile 624 + 0x19	C
 	Apache.exe!mainCRTStartup()  Zeile 398 + 0x11	C

---------------------------------------------------------------------
To unsubscribe, e-mail: bugs-unsubscribe@httpd.apache.org
For additional commands, e-mail: bugs-help@httpd.apache.org


Mime
View raw message