couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul Davis <paul.joseph.da...@gmail.com>
Subject Re: New Externals: Implemented with tests
Date Mon, 04 Oct 2010 17:44:00 GMT
On Mon, Oct 4, 2010 at 12:26 PM, Benoit Chesneau <bchesneau@gmail.com> wrote:
> On Mon, Oct 4, 2010 at 5:49 PM, Paul Davis <paul.joseph.davis@gmail.com> wrote:
>
>> I'm not entirely sure about rewriting headers. For the most part I
>> wanted to make sure that I wasn't modifying headers in anyway. If
>> there's a specific set of headers that need to be handled then we can
>> take a look at adding that in.
>>
> At least Location need cleaning at least since you get full headers
> and pass them to mochiweb directly in start_response. A remote server
> can set a Location to /some/path but you display behind
> /_proxied/some/path. Also during redirection (302/303) , rewriting
> locaton may be needed too though redirecting isn't handled yet.
>
> I've already some code for that from couchdbproxy. Will provide a patch.
> - benoit
>

Actually I need to update the patch. I was reading RFC 2616 the other
day and they specifically state that a proxy is not allowed to rewrite
URL paths.

I'm also not sure about the Location headers. I'll have to go back and
look to see what people are doing in terms of if they're setting
absolute or relative URI's. Theoretically, if they're relative then it
should work just fine.

Paul

Mime
View raw message