Skip Menu |

This queue is for tickets about the HTTP-Proxy CPAN distribution.

Report information
The Basics
Id: 18244
Status: rejected
Priority: 0/
Queue: HTTP-Proxy

People
Owner: book [...] cpan.org
Requestors: stennie [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 0.17
Fixed in: (no value)



Subject: requests_redirectable option deviates from default (expected) behaviour
Hi, Is there a reason that requests_redirectable has been explicitly overridden from the default (expected) behaviour: $self->agent->requests_redirectable( [] ); From the LWP::UserAgent doc page: This reads or sets the object's list of request names that $ua->redirect_ok(...) will allow redirection for. By default, this is ['GET', 'HEAD'], as per RFC 2616. Attached is a patch against 0.17 which removes the offending line ;-). Cheers, Stephen @@ -207,7 +207,6 @@ $self->_init_agent if ( !defined $self->agent ); # specific agent config - $self->agent->requests_redirectable( [] ); $self->agent->agent(''); # for TRACE support $self->agent->protocols_allowed( [qw( http https ftp gopher )] );
Show quoted text
> From the LWP::UserAgent doc page: > This reads or sets the object's list of request names that $ua-
> >redirect_ok(...) will allow
> redirection for. By default, this is ['GET', 'HEAD'], as per RFC 2616.
Note .. if you want to support proxying webdav for svn, you need to replace: $self->agent->requests_redirectable( [] ); With: push @{ $self->agent->requests_redirectable }, 'PROPFIND'; Cheers, Stephen
Le Dim. Mar. 19 11:48:45 2006, stennie a écrit : Show quoted text
> Hi, > > Is there a reason that requests_redirectable has been explicitly > overridden from the default > (expected) behaviour: > $self->agent->requests_redirectable( [] );
Yes there is. By default, the proxy is supposed to handle single requests as single requests. So, no redirection is followed by default, but rather sent back to the client who should react to the 3xx response itself. That's also the reason why it uses simple_request() rather than request().