My favorites | Sign in
Project Logo
Project hosting will be READ-ONLY Wednesday at 8am PST due to brief network maintenance.
                
New issue | Search
for
| Advanced search | Search tips
Issue 39: https with proxy server doesn't work
2 people starred this issue and may be notified of changes. Back to list
Status:  Fixed
Owner:  ----
Closed:  Mar 2008
Type-Defect
Priority-Medium


Sign in to add a comment
 
Reported by chrisrd, Dec 10, 2007
What steps will reproduce the problem?

------------------------------------------------
use WWW::Mechanize;
$ENV{HTTPS_PROXY} = $your_proxy_setting;
my $mech = WWW::Mechanize->new();
$mech->get('https://mail.google.com/');
print "status: ", $mech->status(), "\n";
------------------------------------------------

What is the expected output? What do you see instead?

Expected: status: 200
Got: status: 501

What version of the product are you using? On what operating system?

WWW::Mechanize 1.34
LWP 5.805
Crypt::SSLeay  0.51

Debian etch

Please provide any additional information below.

WWW::Mechanize::new() automatically calls LWP::UserAgent::env_proxy(),
which then, for reasons obscure to me, bypasses the SSL proxy mechanism.

The attached patch fixes this if you pass 'noproxy => 1' to the new(), e.g.:

  my $mech = WWW::Mechanize->new(noproxy => 1);
 
Alternatively, remove the call to env_proxy() altogether in
WWW::Mechanize::new. This would then allow people to call
env_proxy() themselves as required.

www-mechanize-proxy.patch
992 bytes   Download
Comment 1 by petdance, Mar 10, 2008
Added in whatever comes after 1.34.
Status: Fixed
Sign in to add a comment

Hosted by Google Code