You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apache-bugdb@apache.org by Ron Klatchko <ro...@ckm.ucsf.edu> on 1998/10/09 22:01:10 UTC

mod_auth-any/3171: mod_auth_db does not work properly with Berkeley DB 2.x

>Number:         3171
>Category:       mod_auth-any
>Synopsis:       mod_auth_db does not work properly with Berkeley DB 2.x
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    apache
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Fri Oct  9 13:10:00 PDT 1998
>Last-Modified:
>Originator:     ron@ckm.ucsf.edu
>Organization:
apache
>Release:        1.3.2
>Environment:
mod_auth_db, Berkeley DB 2.3.16
Solaris 2.6
gcc 2.7.2.2
>Description:
mod_auth_db does not work properly with Berkeley DB 2.x API.  It requires the
file to be writable to be able to open it and even then, it does not find
the needed entries.
>How-To-Repeat:
Compile mod_auth_db against a Berkeley 2.x version and then try to use
AuthDBUserFile
>Fix:
The following patches worked for me:

# diff mod_auth_db.c mod_auth_db.c.dist
158,160d157
<     memset(&d, '\0', sizeof(d));
<     memset(&q, '\0', sizeof(q));
< 
165c162
<     if (db_open(auth_dbpwfile, DB_HASH, DB_RDONLY, 0664, NULL, NULL,  &f) != 0) {
---
>     if (db_open(auth_dbpwfile, DB_HASH, O_RDONLY, 0664, NULL, NULL,  &f) != 0) {
>Audit-Trail:
>Unformatted:
[In order for any reply to be added to the PR database, ]
[you need to include <ap...@Apache.Org> in the Cc line ]
[and leave the subject line UNCHANGED.  This is not done]
[automatically because of the potential for mail loops. ]
[If you do not include this Cc, your reply may be ig-   ]
[nored unless you are responding to an explicit request ]
[from a developer.                                      ]
[Reply only with text; DO NOT SEND ATTACHMENTS!         ]