Commit 759ab87d authored by Jeff Trawick's avatar Jeff Trawick
Browse files

Merge r1070096 from trunk:

Log something nicer than "Internal error: pcfg_openfile() called
with NULL filename" if no password file is configured

Submitted by: sf
Reviewed by: igalic, rpluem 


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/branches/2.2.x@1070648 13f79535-47bb-0310-9956-ffa450edef68
parent 1fe50460
Loading
Loading
Loading
Loading
+0 −6
Original line number Diff line number Diff line
@@ -90,12 +90,6 @@ RELEASE SHOWSTOPPERS:
PATCHES ACCEPTED TO BACKPORT FROM TRUNK:
  [ start all new proposals below, under PATCHES PROPOSED. ]

  * mod_authn_file: Log friendly error message if AuthUserFile is not set.
      Trunk version of patch:
         http://svn.apache.org/viewcvs.cgi?rev=1070096&view=rev
      Backport version for 2.2.x of patch:
         Trunk version of patch works with offset
      +1: sf, igalic, rpluem

PATCHES PROPOSED TO BACKPORT FROM TRUNK:
  [ New proposals should be added at the end of the list ]
+12 −0
Original line number Diff line number Diff line
@@ -70,6 +70,12 @@ static authn_status check_password(request_rec *r, const char *user,
    apr_status_t status;
    char *file_password = NULL;

    if (!conf->pwfile) {
        ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
                      "AuthUserFile not specified in the configuration");
        return AUTH_GENERAL_ERROR;
    }

    status = ap_pcfg_openfile(&f, r->pool, conf->pwfile);

    if (status != APR_SUCCESS) {
@@ -118,6 +124,12 @@ static authn_status get_realm_hash(request_rec *r, const char *user,
    apr_status_t status;
    char *file_hash = NULL;

    if (!conf->pwfile) {
        ap_log_rerror(APLOG_MARK, APLOG_ERR, 0, r,
                      "AuthUserFile not specified in the configuration");
        return AUTH_GENERAL_ERROR;
    }

    status = ap_pcfg_openfile(&f, r->pool, conf->pwfile);

    if (status != APR_SUCCESS) {