You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@httpd.apache.org by "Roy T. Fielding" <fi...@avron.ICS.UCI.EDU> on 1995/10/30 22:44:39 UTC

Re: uploaded 37_tilde_ok.0.8.15.patch

>> One of the earlier releases that I didn't test on my server changed
>> the handling of patch escapes such that all FancyIndex URL paths
>> are escaped.  Unfortunately, Apache uses the "~" character for default
>> user directory prefixes.  The result is that Apache 0.8.15 is changing
>> the URL from /~user to /%7euser in a rather arbitrary fashion.
> 
> Huh? I can't find code that does this via mod_dir anywhere? As far as I can
> see, mod_dir paths are always relative. How do I reproduce this problem?

mod_dir calls os_escape_path when it builds a fancy index.  To reproduce
the problem, create a ~user/public_html directory and test subdirectory,
put some files in the test subdirectory, turn on FancyIndexing, and go to
      
     /~user/test/

and look at the URLs generated by the fancy index.  For illustration,
select the Parent Directory anchor and you will be sent to

     /%7euser/

which is not what we want to happen.

> Besides, is this the correct way to fix the problem? What if the file really
> starts with a ~?

Makes no difference -- the client will not interpret the "~" character
any differently than "%7e", and that is all that matters here.  The correct
behavior (for Apache) is to treat "~" as a normal character.

.....Roy