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 39985] - mod_dbd shutdown double free via dbd_close
Date Sat, 20 Jan 2007 20:30:47 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=39985>.
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=39985





------- Additional Comments From poeml@suse.de  2007-01-20 12:30 -------
I hope I got the backport right. It works for me, so far. 

I didn't test other drivers than mysql, but I tried it with both prefork and worker.

My testcase is as described below.

The entire conf is:
--------------
User wwwrun
Group www
ErrorLog /var/log/apache2/error_log
Listen 81

DBDriver mysql
DBDParams "host=localhost, user=theuser, pass=thepass, dbname=thedbname"
<Directory /srv/www/htdocs/mysql-test>
        AuthType Basic
        AuthName "MySQL Testing"
        AuthBasicProvider dbd
        Require valid-user
        AuthDBDUserPWQuery "select password from user where username=%s"
</Directory>
---------------

The server is built with the 2.2.4 tarball, and putting http://apache.webthing.com/svn/apache/apr/
apr_dbd_mysql.c into srclib/apr-util. In order to build the mysql driver, I used the following
patch:

Index: build-outputs.mk
===============================================================
====
--- build-outputs.mk.orig       2006-11-29 12:48:46.000000000 +0100
+++ build-outputs.mk    2006-12-13 17:17:33.413014156 +0100
@@ -45,8 +45,9 @@ dbd/apr_dbd.lo: dbd/apr_dbd.c .make.dirs
 dbd/apr_dbd_sqlite2.lo: dbd/apr_dbd_sqlite2.c .make.dirs
 dbd/apr_dbd_sqlite3.lo: dbd/apr_dbd_sqlite3.c .make.dirs
 dbd/apr_dbd_pgsql.lo: dbd/apr_dbd_pgsql.c .make.dirs
+dbd/apr_dbd_mysql.lo: dbd/apr_dbd_mysql.c .make.dirs include/apu_version.h
 
-OBJECTS_all = buckets/apr_buckets_pipe.lo buckets/apr_buckets_flush.lo buckets/
apr_buckets_alloc.lo buckets/apr_buckets_pool.lo buckets/apr_buckets_socket.lo buckets/
apr_buckets_heap.lo buckets/apr_buckets_simple.lo buckets/apr_buckets_file.lo buckets/
apr_buckets.lo buckets/apr_buckets_mmap.lo buckets/apr_buckets_eos.lo buckets/apr_brigade.lo

buckets/apr_buckets_refcount.lo crypto/apr_sha1.lo crypto/uuid.lo crypto/getuuid.lo crypto/
apr_md5.lo crypto/apr_md4.lo dbm/apr_dbm.lo dbm/apr_dbm_berkeleydb.lo dbm/apr_dbm_gdbm.lo

dbm/apr_dbm_ndbm.lo dbm/apr_dbm_sdbm.lo dbm/sdbm/sdbm_pair.lo dbm/sdbm/sdbm.lo dbm/
sdbm/sdbm_hash.lo dbm/sdbm/sdbm_lock.lo encoding/apr_base64.lo hooks/apr_hooks.lo ldap/
apr_ldap_url.lo ldap/apr_ldap_option.lo ldap/apr_ldap_init.lo misc/apr_reslist.lo misc/apu_version.lo

misc/apr_date.lo misc/apr_rmm.lo misc/apr_queue.lo uri/apr_uri.lo xml/apr_xml.lo strmatch/
apr_strmatch.lo xlate/xlate.lo dbd/apr_dbd.lo dbd/apr_dbd_sqlite2.lo dbd/apr_dbd_sqlite3.lo
dbd/
apr_dbd_pgsql.lo
+OBJECTS_all = buckets/apr_buckets_pipe.lo buckets/apr_buckets_flush.lo buckets/
apr_buckets_alloc.lo buckets/apr_buckets_pool.lo buckets/apr_buckets_socket.lo buckets/
apr_buckets_heap.lo buckets/apr_buckets_simple.lo buckets/apr_buckets_file.lo buckets/
apr_buckets.lo buckets/apr_buckets_mmap.lo buckets/apr_buckets_eos.lo buckets/apr_brigade.lo

buckets/apr_buckets_refcount.lo crypto/apr_sha1.lo crypto/uuid.lo crypto/getuuid.lo crypto/
apr_md5.lo crypto/apr_md4.lo dbm/apr_dbm.lo dbm/apr_dbm_berkeleydb.lo dbm/apr_dbm_gdbm.lo

dbm/apr_dbm_ndbm.lo dbm/apr_dbm_sdbm.lo dbm/sdbm/sdbm_pair.lo dbm/sdbm/sdbm.lo dbm/
sdbm/sdbm_hash.lo dbm/sdbm/sdbm_lock.lo encoding/apr_base64.lo hooks/apr_hooks.lo ldap/
apr_ldap_url.lo ldap/apr_ldap_option.lo ldap/apr_ldap_init.lo misc/apr_reslist.lo misc/apu_version.lo

misc/apr_date.lo misc/apr_rmm.lo misc/apr_queue.lo uri/apr_uri.lo xml/apr_xml.lo strmatch/
apr_strmatch.lo xlate/xlate.lo dbd/apr_dbd.lo dbd/apr_dbd_sqlite2.lo dbd/apr_dbd_sqlite3.lo
dbd/
apr_dbd_pgsql.lo dbd/apr_dbd_mysql.lo
 
 OBJECTS_unix = $(OBJECTS_all)
 


Then I did

./configure --enable-dbd --enable-authn_dbd --with-included-apr && \
make && make install

The database account data must be valid.

In order to reproduce the bug, I used the commands
/usr/local/apache2/bin/httpd
kill $(cat /usr/local/apache2/logs/httpd.pid)


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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


Mime
View raw message