www-apache-bugdb mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tony Holmes <t...@crosswinds.net>
Subject mod_rewrite/6802: Conditional Backreferences in RewriteMaps used in RewriteCond does not work
Date Mon, 06 Nov 2000 17:54:43 GMT

>Number:         6802
>Category:       mod_rewrite
>Synopsis:       Conditional Backreferences in RewriteMaps used in RewriteCond does not
work
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    apache
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   apache
>Arrival-Date:   Mon Nov 06 10:10:04 PST 2000
>Closed-Date:
>Last-Modified:
>Originator:     tony@crosswinds.net
>Release:        1.3.14
>Organization:
apache
>Environment:
FreeBSD db.crosswinds.net 3.4-STABLE FreeBSD 3.4-STABLE #0: Fri Mar 10 16:34:46 EST 2000
gcc version 2.7.2.3
Apache 1.3.14 + mod_rewrite fix diff
>Description:
When using a Condition backreference as a key to a dbm RewriteMap, used in a
RewriteCond statement, the %<n> is not expanded correctly.

This still exists with the mod_rewrite patch fix for 1.3.14
>How-To-Repeat:
Using a DBM rewrite map named foo, here is the httpd.conf lines

RewriteCond %{REQUEST_FILENAME} /[~|%7E]([a-z0-9]*)/$	[NC]
RewriteCond %{foo:%1}	!NO
RewriteRule ^/(.*)$	/someotherurl/$1 [L]

The foo map lookup fails since %1 is passed as tthe key instead of the 
value of the conditional backreference
>Fix:

>Release-Note:
>Audit-Trail:
>Unformatted:
 [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!     ]
 
 


Mime
View raw message