Installing Patches
This module currently requires a few minor patches to the Apache source code for correct operation. In the patches subdirectory, you'll find a patch file:
apache-1.3.9+.diff -- For Apache 1.3.9 and later
This patch should apply (with possible offset complaints) to Apache 1.3.9 and later, including SSL variants thereof. To apply the patch, run the command:
patch -p1 -d /path/to/apache_1.3.x < \
/path/to/mod_auth_dce-3.2/patches/apache-1.3.9+.diff
Technical Details
The following is a list of files modified by the patch and the reasons the modifications needed to be made.
mod_cgi.c
The call to can_exec(), which checks execute permissions by
comparing the server's UID and GID to owner/group permissions
on the file, does not work correctly when a CGI might not be
executable by the server user/group. This call is replaced with
a call to the access() system routine instead, which will take
ACLs into account when deciding whether execute permission
exists.
http_request.c
In the get_path_info() function in this file, the server tries to
separate the request into a system path and the extra PATH_INFO
environment variable. This is accomplished by repeated calls to
stat(), and the removal of the rightmost component of the
request on each stat() failure. This function is called before
any credentials are obtained, and the stat() might fail with a
permission error if the any_other entry does not have access.
This makes the PATH_INFO incorrect. The function is modified to
check for a permission error (EACCES) when stat() fails, and if
it finds one, to immediately return OK with no further processing.
mod_auth_dce will call this function again after credentials
have been obtained, if needed, to correctly separate the PATH_INFO.
This function is also changed to no longer be static, so it may be
called from mod_auth_dce.
Also in get_path_info(), if a DFS server is down, the stat() call
could return ETIMEDOUT. Stock Apache will return HTTP_FORBIDDEN in
this case, which seems wrong. Instead, the function is modified
to return HTTP_SERVICE_UNAVAILABLE.
mod_userdir.c
Similar to the get_path_info() function, a stat() call in
mod_userdir could return ETIMEDOUT. In this case, the function
is modified to return HTTP_SERVICE_UNAVAILABLE.
