line |
true |
false |
branch |
52
|
0 |
1 |
if $depth > 10 |
53
|
0 |
1 |
if $self->_bad_host($host) |
56
|
0 |
1 |
if $host =~ /^\d+\.\d+\.\d+\.\d+$/ |
58
|
0 |
1 |
unless my $dns_ref = $res->bgsend($host) |
63
|
0 |
1 |
if (UNIVERSAL::isa($dns_ref, 'IO::Select')) { } |
73
|
0 |
1 |
unless ($dns_ref and $dns_ref eq 'MOCK') |
77
|
0 |
0 |
unless $nf |
80
|
0 |
1 |
unless my $packet = $res->bgread($dns_ref) |
87
|
1 |
0 |
if ($rr->type eq 'A') { } |
|
0 |
0 |
elsif ($rr->type eq 'CNAME') { } |
88
|
1 |
0 |
if $self->_bad_host($rr->address) |
97
|
0 |
0 |
if @addr |
98
|
0 |
0 |
unless $cname |
107
|
0 |
23 |
unless $self->{$list_name} |
108
|
0 |
35 |
if (ref $rule eq 'CODE') { } |
|
12 |
23 |
elsif (ref $rule) { } |
109
|
0 |
0 |
if &$rule($host) |
112
|
0 |
12 |
if $host =~ /$rule/ |
114
|
1 |
22 |
if $host eq $rule |
123
|
0 |
11 |
if $self->_host_list_match('whitelisted_hosts', $host) |
124
|
0 |
11 |
if $self->_host_list_match('blocked_hosts', $host) |
125
|
0 |
11 |
if $host =~ /^localhost$/i or $host =~ /\s/i |
136
|
0 |
11 |
if @parts > 4 |
141
|
2 |
24 |
unless /^\d+$/ or /^0x[a-f\d]+$/ |
143
|
13 |
11 |
if /^0/ |
147
|
0 |
9 |
if $overflow_flag |
151
|
1 |
8 |
if (@parts == 1) { } |
|
4 |
4 |
elsif (@parts == 2) { } |
|
1 |
3 |
elsif (@parts == 3) { } |
|
3 |
0 |
elsif (@parts == 4) { } |
153
|
0 |
1 |
if $parts[0] > 4294967295 |
158
|
0 |
4 |
if $parts[0] > 255 or $parts[1] > 16777215 |
164
|
0 |
1 |
if $parts[0] > 255 or $parts[1] > 255 or $parts[2] > 65535 |
171
|
0 |
3 |
if $parts[0] > 255 or $parts[1] > 255 or $parts[2] > 255 or $parts[3] > 255 |
182
|
1 |
1 |
if ($haddr & 4278190080) == 0 or ($haddr & 4278190080) == 167772160 or ($haddr & 4278190080) == 2130706432 or ($haddr & 4293918720) == 2886729728 or ($haddr & 4294901760) == 2851995648 or ($haddr & 4294901760) == 3232235520 or ($haddr & 4294967040) == 3221225984 or ($haddr & 4294967040) == 3227017984 or $haddr == 4294967295 or ($haddr & 4026531840) == 3758096384 |
197
|
1 |
0 |
if $self->_host_list_match('blocked_hosts', $can_ip) |
210
|
0 |
9 |
$first_res ? : |
213
|
8 |
1 |
if ($self->_bad_host($host)) |
223
|
0 |
1 |
if (my $pp = $self->{'paranoid_proxy'}) |
244
|
0 |
1 |
unless $method |
246
|
0 |
1 |
unless $url |
248
|
0 |
1 |
unless $url->scheme |
250
|
0 |
1 |
if $self->_need_proxy($url) |
256
|
0 |
1 |
unless $scheme eq 'http' or $scheme eq 'https' |
267
|
0 |
1 |
if ($x = $self->protocols_allowed) { } |
|
0 |
1 |
elsif ($x = $self->protocols_forbidden) { } |
268
|
0 |
0 |
if (grep((lc $_ eq $scheme), @$x)) { } |
278
|
0 |
0 |
if (grep((lc $_ eq $scheme), @$x)) { } |
290
|
1 |
0 |
unless ($protocol) |
293
|
0 |
1 |
if ($@) |
299
|
1 |
0 |
$scheme eq 'http' ? : |
300
|
0 |
1 |
if ($@) |
303
|
0 |
0 |
if ($scheme eq 'https') |
321
|
1 |
0 |
if ($use_eval) { } |
328
|
1 |
0 |
if ($error) |
342
|
0 |
1 |
if $cookie_jar |
344
|
1 |
0 |
if $self->can('run_handlers') |
352
|
1 |
0 |
if (@_) |
357
|
0 |
0 |
unless $self->{'blocked_hosts'} |
364
|
1 |
0 |
if (@_) |
369
|
0 |
0 |
unless $self->{'whitelisted_hosts'} |
376
|
2 |
1 |
if (@_) |
380
|
0 |
2 |
unless UNIVERSAL::isa($self->{'resolver'}, 'Net::DNS::Resolver') |
390
|
0 |
1 |
unless ref $url |
393
|
0 |
1 |
if (my $proxy = $self->{'proxy'}{$scheme}) |
394
|
0 |
0 |
if ($self->{'no_proxy'} and @{$self->{'no_proxy'};}) |
395
|
0 |
0 |
if (my $host = eval {
do {
$url->host
}
}) |
397
|
0 |
0 |
if ($host =~ /\Q$domain\E$/) |
416
|
1 |
0 |
if (defined $request) { } |
417
|
1 |
0 |
if (ref $request) { } |
418
|
0 |
1 |
if ref $request eq 'ARRAY' or ref $request eq 'HASH' or not $request->can('method') or not $request->can('uri') |