Re: proxies rewriting URLs

>I think that it is a question of what people can encode into URIs. 
>URIs do not specify a canonical form so that there can be several
>URIs which logically mean the same thing.
>If we are clear on the "meaning" part then two syntactic variants
>of the same URI should be interchangeable. If something breaks
>because of this problem then it is something which relied upon a
>syntactic variation and was therefore broken.
>I can think of many reasons why
>a proxy might choose to canonicalize URIs internally, cache matches
>for one. If one considers the action of a caching proxy I think that
>canonicalization of URIs in passed on requests is likely to be highly
>Since Larry reports that there are already proxies doing this sort of 
>transformation I think it best to leave things as they are but include
>a warning to state that problems might occur.


A proxy that did not return the cached document http://foo/%7Euser
in response to a requset for http://foo/~user is not behaving efficiently.
So proxies need to canonicalise the URL for the cache key.
Hence it would be confusing if the proxy did not use this canonicalised URL
in requests it issued.

This is why the proxy in Apache 1.1 beta does a lot of URL rewriting;
not only %xx <-> char as appropiate, but also
http://foo  -> http://foo/
and (perhaps dubiously) http://foo/bar? -> http://foo/bar

 David Robinson.

Received on Monday, 11 March 1996 10:05:00 UTC