httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 51434] New: Unable to use (forward) slashes in a FilterProvider regex
Date Sat, 25 Jun 2011 11:22:13 GMT

             Bug #: 51434
           Summary: Unable to use (forward) slashes in a FilterProvider
           Product: Apache httpd-2
           Version: 2.2.17
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: mod_filter
    Classification: Unclassified

For example the following FilterProvider will cause an internal server error.
("Bad regexp" in the error_log)

FilterDeclare  COMPRESS
FilterProvider COMPRESS DEFLATE resp=Content-Type /text\/(html|css)/
FilterChain    COMPRESS
FilterProtocol COMPRESS change=yes;byteranges=no

After looking at the actual code (My c/c++ knowledge is only limited) it seems
the second (forward) slash is always the delimiter of the regex, even when it's
escaped. Then it tries to parse the regex 'text\', this is indeed a bad regexp.

So it seems it's impossible to use a forward slash in a FilterProvider regex.

I found out about this issue while looking at the usage of mod_filter in
html5boilerplate. For more information see this issue:

I tested this using Apache/2.2.17 on Ubuntu 11.04

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message