www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Line <web...@info.cam.ac.uk>
Subject mod_rewrite/5723: RewriteOptions bug (and/or documentation misleading)
Date Tue, 08 Feb 2000 15:15:59 GMT

>Number:         5723
>Category:       mod_rewrite
>Synopsis:       RewriteOptions bug (and/or documentation misleading)
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    apache
>State:          open
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Tue Feb 08 07:20:00 PST 2000
>Originator:     webadm@info.cam.ac.uk
>Release:        1.3.9
Solaris 2.6 (SPARC CPU), Sun's ANSI C compiler
The documentation for RewriteOptions says

Context: server config, virtual host, directory, .htaccess

but that is either misleading or divergent from reality. 

It implies that you can use "RewriteOptions: inherit" in the main part of the 
configuration file (outside any Virtualhost sections). That is true in the 
sense that RewriteOptions is accepted in the main part of the configuration 
file without error, but in a configuration with two name-based virtual hosts
sharing a single IP address, it had no effect until I moved it inside one of the
<VirtualHost> sections. RewriteRules defined in the main (non-virtual) part of
the configuration were ignored until RewriteOptions was set in the virtual
host sections, at which point they were inherited as I'd intended.

The documentation does not actually say what effect RewriteOptions in the main 
part of the configuration file should have; the obvious interpretation and
what I expected was that it would cause the non-virtualhost rewriting rules
to be inherited by all virtual servers unless overridden by vhost-specific
settings (with vhost-specific rules merged in after the inherited ones) - 
that seems likely to be a common requirement for handling "standard" rules 
to exclude misbehaving indexing robots and suchlike, and a single overall 
setting would make the situation much clearer and reduces the risk of 
inconsistent configuration.

Anyway, depending on whether it's viewed as a primarily documentation bug
or a software bug, either

(a) mod_rewrite should apply a suitable interpretation to RewriteOptions when
used in the main (non-vhost) part of the configuration file (rather than 
ignoring it as at present), and the documentation should make clear what it 
does when used in that way, or 

(b) the documentation should make clear that RewriteOptions is not valid
in the main (non-vhost) part if the configuration file, and mod_rewrite should
report as an error any attempt to use it there.


 [In order for any reply to be added to the PR database, you need]
 [to include <apbugs@Apache.Org> in the Cc line and make sure the]
 [subject line starts with the report component and number, with ]
 [or without any 'Re:' prefixes (such as "general/1098:" or      ]
 ["Re: general/1098:").  If the subject doesn't match this       ]
 [pattern, your message will be misfiled and ignored.  The       ]
 ["apbugs" address is not added to the Cc line of messages from  ]
 [the database automatically because of the potential for mail   ]
 [loops.  If you do not include this Cc, your reply may be ig-   ]
 [nored unless you are responding to an explicit request from a  ]
 [developer.  Reply only with text; DO NOT SEND ATTACHMENTS!     ]

View raw message