- From: <bugzilla@jessica.w3.org>
- Date: Thu, 15 Nov 2012 23:13:20 +0000
- To: www-validator-cvs@w3.org
https://www.w3.org/Bugs/Public/show_bug.cgi?id=19974
Priority: P2
Bug ID: 19974
Assignee: ville.skytta@iki.fi
Summary: The link checker will use a proxy and it will handle
https but it does not do both
QA Contact: www-validator-cvs@w3.org
Severity: major
Classification: Unclassified
OS: All
Reporter: mark.g.pohl@gmail.com
Hardware: PC
Status: NEW
Version: unspecified
Component: checklink
Product: LinkChecker
The link checker will use a proxy just fine with http but if you use a proxy
with https it will not send the https through the proxy. It will time out.
There is a simple fix for this. There is a simple fix. Here is the code to
replace the current "new" constructor. The comment and new code start at line
29 in the method
sub new
{
my $proto = shift;
my $class = ref($proto) || $proto;
my ($name, $from, $rules) = @_;
# For security/privacy reasons, if $from was not given, do not send it.
# Cheat by defining something for the constructor, and resetting it later.
my $from_ok = $from;
$from ||= 'www-validator@w3.org';
my $self;
if (USE_ROBOT_UA) {
$self = $class->SUPER::new($name, $from, $rules);
}
else {
my %cnf;
@cnf{qw(agent from)} = ($name, $from);
$self = LWP::UserAgent->new(%cnf);
$self = bless $self, $class;
}
$self->from(undef) unless $from_ok;
$self->env_proxy();
#Added this to set the proxy for https as well as http
#This is not included with the standard distribution.
#The standard distribution will work with a proxy and will work with https
but it
#does not work with both a proxy and https at the same time.
$self->{proxy} = { https => $ua->{proxy}->{http},
http => $ua->{proxy}->{http}
};
$self->allow_private_ips(1);
$self->protocols_forbidden([qw(mailto javascript)]);
return $self;
}
--
You are receiving this mail because:
You are the QA Contact for the bug.
Received on Thursday, 15 November 2012 23:13:21 UTC