Package: libapache2-mod-vhost-ldap Version: 2.0.5-1 Tags: patch When an apacheConfig record is configured with an apacheScriptAlias directory, mod_vhost_ldap 1.2.0 would serve that directory at /cgi-bin, but this seems to have broken in 2.0.x. The following patch makes it work again.
(BTW, I did not have problems with mod_rewrite using mod_vhost_ldap 1.2.0, which always returned OK instead of DECLINED. What problem does DECLINED solve?) -- 8< -- >From e56e6d60589d91a30a875ee5aaa329c41bc794dc Mon Sep 17 00:00:00 2001 From: Anders Kaseorg <[email protected]> Date: Sat, 17 Jul 2010 18:26:16 -0400 Subject: [PATCH] Return OK when we set r->filename, to fix cgi-bin URLs. Signed-off-by: Anders Kaseorg <[email protected]> --- mod_vhost_ldap.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/mod_vhost_ldap.c b/mod_vhost_ldap.c index 3c5cde9..022dda1 100644 --- a/mod_vhost_ldap.c +++ b/mod_vhost_ldap.c @@ -452,6 +452,7 @@ static int mod_vhost_ldap_translate_name(request_rec *r) int sleep1 = 1; int sleep; struct berval hostnamebv, shostnamebv; + int ret = DECLINED; reqc = (mod_vhost_ldap_request_t *)apr_pcalloc(r->pool, sizeof(mod_vhost_ldap_request_t)); @@ -622,6 +623,7 @@ null: r->filename = cgi; r->handler = "cgi-script"; apr_table_setn(r->notes, "alias-forced-type", r->handler); + ret = OK; } } else if (r->uri[0] == '/') { /* we don't set r->filename here, and let other modules do it @@ -687,7 +689,7 @@ null: } /* Hack to allow post-processing by other modules (mod_rewrite, mod_alias) */ - return DECLINED; + return ret; } #ifdef HAVE_UNIX_SUEXEC -- 1.7.2.rc2 -- To UNSUBSCRIBE, email to [email protected] with a subject of "unsubscribe". Trouble? Contact [email protected]

