Subject: pkg/37362: Patch problem for www/ap-auth-external package
To: None <pkg-manager@netbsd.org, gnats-admin@netbsd.org,>
From: None <jeanyves.migeon@free.fr>
List: pkgsrc-bugs
Date: 11/11/2007 21:15:04
>Number:         37362
>Category:       pkg
>Synopsis:       Patch problem for www/ap-auth-external package
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Nov 11 21:15:04 +0000 2007
>Originator:     Jean-Yves Migeon
>Release:        3.1
>Organization:
None
>Environment:
NetBSD minas-morgul 3.1 NetBSD 3.1 (GENERIC) #0: Tue Oct 31 04:27:07 UTC 2006 builds@b0.netbsd.org:/home/builds/ab/netbsd-3-1-RELEASE/i386/200610302053Z-obj/home/builds/ab/netbsd-3-1-RELEASE/src
/sys/arch/i386/compile/GENERIC i386

pkgsrc revision is -current.
>Description:
The patch step when building the ap-auth-external package fails when installing the Apache 2 API version of the mod_auth_external module.

Apache API's between version 1.3 and 2 are totally different, and some routines had their names changed.

The patch-aa file provided with www/ap-auth-external package works for the module built upon Apache API v1.3, and not API v2.

>How-To-Repeat:
# cd /usr/pkgsrc/www/apache2 && make install
# cd /usr/pkgsrc/www/ap-auth-external && make install
>Fix:
When the patch file is modified accordingly to the 2.0 API, ap-auth-external package is successfully built and works when loaded into httpd.conf (LoadModule).

Please find enclosed below the Apache 2.0 API patch, which should be used instead of the one currently provided in pkgsrc when building ap-auth-external package against www/apache2 package.

--- mod_auth_external.c.orig    2006-02-15 23:44:53.000000000 +0100
+++ mod_auth_external.c 2007-11-10 20:49:51.000000000 +0100
@@ -242,6 +242,7 @@
#define ENV_PASS       "PASS"
#define ENV_GROUP      "GROUP"
#define ENV_URI                "URI"
+#define ENV_METHOD     "METHOD"
#define ENV_IP         "IP"
#define ENV_HOST       "HOST"          /* Remote Host */
#define ENV_HTTP_HOST   "HTTP_HOST"    /* Local Host */
@@ -506,6 +507,9 @@
       if (r->uri)
           child_env[i++]= apr_pstrcat(r->pool, ENV_URI"=", r->uri, NULL);

+       if (r->method)
+           child_env[i++]= apr_pstrcat(r->pool, ENV_METHOD"=", r->method, NULL);
+
       if ((host= lookup_header(r,"Host")) != NULL)
           child_env[i++]= apr_pstrcat(r->pool, ENV_HTTP_HOST"=", host, NULL);


Best regards,
Jean-Yves.