You are viewing a plain text version of this content. The canonical link for it is here.
Posted to apache-bugdb@apache.org by Chris Teakle <cc...@cc.uq.edu.au> on 1998/01/16 13:21:47 UTC
mod_rewrite/1684: RewriteLog directive does the equivalent of "HostnameLookups on".
>Number: 1684
>Category: mod_rewrite
>Synopsis: RewriteLog directive does the equivalent of "HostnameLookups on".
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: apache
>State: open
>Class: sw-bug
>Submitter-Id: apache
>Arrival-Date: Fri Jan 16 04:30:00 PST 1998
>Last-Modified:
>Originator: ccteakle@cc.uq.edu.au
>Organization:
apache
>Release: 1.2.5
>Environment:
Digital Unix 4.0, built with gcc 2.7.2.2.
uname -a yields "OSF1 yarama.cc.uq.edu.au V4.0 386 alpha"
>Description:
Using a RewriteLog directive causes DNS lookups to be performed on all accesses
and causes hostname to be used instead of IP addresses in access_log (and the
rewrite log file itself). It does not matter that there is a "HostnameLookups off"
directive.
The problem only seems to manifest itself if there is a non-trivial access.conf
configuration. E.g. more than one Directory definition.
The problem does not occur with this access.conf:
<Directory /usr/local/httpd/htdocs>
Options Indexes SymlinksIfOwnerMatch
AllowOverride Limit
<Limit GET>
order deny,allow
deny from all
allow from 130.102
</Limit>
</Directory>
But it does if the following is added:
<Directory /*/public_html*>
Options SymlinksIfOwnerMatch
</Directory>
The httpd.conf is simple, with these being the only rewrite-related directives:
RewriteEngine on #Use this to turn rewrite on and off!!
RewriteLog "/usr/local/httpd/logs/rewrite.log"
#Rewriterule /~zz(.*$) http://www.uq.net.au/~zz$1 [R]
In fact you don't even need a Rewriterule directive for the problem to occur.
>How-To-Repeat:
The full description should give sufficient info to repeat the problem.
I can provide full config files if required.
>Fix:
I suspect the problem is in get_remote_host(), or in the way it is called
from the rewritelog() function in mod_rewrite.c
My workaround is to turn off RewriteLog.
%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. ]