You are viewing a plain text version of this content. The canonical link for it is here.
Posted to docs@httpd.apache.org by bu...@apache.org on 2012/12/15 18:33:51 UTC

[Bug 54307] New: Alias/AliasMatch does'n/does fold/match multiple slashes

https://issues.apache.org/bugzilla/show_bug.cgi?id=54307

            Bug ID: 54307
           Summary: Alias/AliasMatch does'n/does fold/match multiple
                    slashes
           Product: Apache httpd-2
           Version: 2.4-HEAD
          Hardware: All
                OS: All
            Status: NEW
          Severity: major
          Priority: P2
         Component: Documentation
          Assignee: docs@httpd.apache.org
          Reporter: calestyo@scientia.net
    Classification: Unclassified

Hi.

Marking this as major, as it quite changes the behaviour of Alias/AliasMatch.

This is similar to what's already correctly documented at the <Location>
directive in the “Note about / (slash)” box there
(https://httpd.apache.org/docs/trunk/mod/core.html#location).


The Alias directive apparently implicitly folds/matches any number of
_consecutive_ slashes (/).
Thus:
Alias /foo/bar /some/file
will apply to e.g. URIs:
/foo/bar
/foo///bar
////foo////bar
etc.


As with Location vs. LocationMatch, this seems to be _NOT_ the case for
AliasMatch, thus e.g.:
AliasMatch "^/foo/bar$" /some/file
will apply to  URIs:
/foo/bar
but _not_ to:
/foo///bar
////foo////bar
(*)


I think this needs to be documented in both directives, Alias and AliasMatch,
similar as it is done as with Location/LocationMatch.


Cheers,
Chris.

(*) Interestingly it _DOES_ fold/match such URIs where there are only multiple
leading slashes, so.e.g.:
AliasMatch "^/foo/bar$" /some/file
will apply to  URIs:
/////foo/bar

I consider this rather a functioal bug and will report it as a separate bug. If
that is not accepted a functional bug, that strange special behaviour should be
documented, too.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


[Bug 54307] Alias/AliasMatch does'n/does fold/match multiple slashes

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54307

--- Comment #1 from Eric Covener <co...@gmail.com> ---
*** Bug 54308 has been marked as a duplicate of this bug. ***

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

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


[Bug 54307] Alias/AliasMatch does'n/does fold/match multiple slashes

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54307

--- Comment #4 from Eric Covener <co...@gmail.com> ---
dropped "leading" from mod_alias update and re-opened other bug.

re; reading the bug reports, sometimes less is more.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


[Bug 54307] Alias/AliasMatch does'n/does fold/match multiple slashes

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54307

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|---                         |FIXED

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

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


[Bug 54307] Alias/AliasMatch does'n/does fold/match multiple slashes

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54307

Christoph Anton Mitterer <ca...@scientia.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |---

--- Comment #3 from Christoph Anton Mitterer <ca...@scientia.net> ---
Hi Eric.

Did you fully read may two bugs?

1) AFAICS this is not yet in https://httpd.apache.org/docs/trunk/ ... right?
But if you just added what you wrote above, then IMHO this is not enough.

First, as I wrote,... not only leading / are folded, but also any within the
string.
Second, I think one should more emphasize the difference in / handling between
Alias and Alias match, as it is done with Location/LocationMatch.

If you'd want to just place all this in the non-Match version of the directive
(Alias) I'm in principle fine,...


2) I don't quite understand why you've marked bug 54308 a duplicate of this?
Here it's about documentation,.. there it's about illogical behaviour.
So can you please explain why it is considered correct that with AliasMatch,
one cannot control the matching on leading slashes, as one can e.g. with
LocationMatch


Thanks,
Chris.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org


[Bug 54307] Alias/AliasMatch does'n/does fold/match multiple slashes

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=54307

Eric Covener <co...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #2 from Eric Covener <co...@gmail.com> ---
Added to Alias directive entry in 2.2 and up:

    <p>Any number of leading slashes in the <var>URL-path</var> parameter
    matches any number of leading slashes in the requested URL-path.</p>

I didn't see any reason to document it in AliasMatch where the regex is applied
directly.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: docs-unsubscribe@httpd.apache.org
For additional commands, e-mail: docs-help@httpd.apache.org