| blib/lib/LightTCP/SSLclient.pm | |||
|---|---|---|---|
| Criterion | Covered | Total | % |
| condition | 29 | 123 | 23.5 |
| line | !l | l&&!r | l&&r | condition |
|---|---|---|---|---|
| 137 | 0 | 0 | 0 | defined $read and $read > 0 |
| 185 | 2 | 0 | 0 | $self->{'cert'} and -f $self->{'cert'} . '.key' |
| 2 | 0 | 0 | $self->{'cert'} and -f $self->{'cert'} . '.key' and -f $self->{'cert'} . '.crt' | |
| 200 | 2 | 0 | 0 | $proxy_host and $proxy_port |
| 273 | 0 | 0 | 0 | $self->{'_target_host'} and $self->{'_target_port'} |
| 337 | 0 | 0 | 0 | $send_ok and $length > 0 |
| 351 | 0 | 0 | 0 | $send_ok and defined $payload |
| 0 | 0 | 0 | $send_ok and defined $payload and $length > 0 | |
| 395 | 0 | 0 | 0 | $self->{'follow_redirects'} and $code >= 300 |
| 0 | 0 | 0 | $self->{'follow_redirects'} and $code >= 300 and $code < 400 | |
| 0 | 0 | 0 | $self->{'follow_redirects'} and $code >= 300 and $code < 400 and $headers | |
| 0 | 0 | 0 | $self->{'follow_redirects'} and $code >= 300 and $code < 400 and $headers and $headers->{'location'} | |
| 433 | 0 | 0 | 0 | $uri->port and $uri->port != 443 |
| 540 | 0 | 0 | 0 | defined $content_length and $content_length > length $body |
| 563 | 0 | 0 | 0 | defined $read and $read > 0 |
| 610 | 0 | 0 | 0 | defined $chunk_line and length $chunk_line |
| 622 | 0 | 0 | 0 | defined $read and $read > 0 |
| 781 | 0 | 1 | 1 | defined $size && $size > 0 |
| line | l | !l | condition |
|---|---|---|---|
| 47 | 1 | 30 | $opts{'timeout'} // 10 |
| 1 | 30 | $opts{'insecure'} // 0 | |
| 0 | 31 | $opts{'cert'} // undef | |
| 7 | 24 | $opts{'verbose'} // 0 | |
| 1 | 30 | $opts{'ssl_protocols'} // ["TLSv1.2", "TLSv1.3"] | |
| 1 | 30 | $opts{'ssl_ciphers'} // "HIGH:!aNULL:!MD5:!RC4" | |
| 2 | 29 | $opts{'keep_alive'} // 0 | |
| 2 | 29 | $opts{'buffer_size'} // 8192 | |
| 2 | 29 | $opts{'max_redirects'} // 5 | |
| 3 | 28 | $opts{'follow_redirects'} // 1 | |
| 89 | 0 | 0 | $$buffer_ref //= "" |
| 299 | 0 | 0 | $opts{'host'} // "" |
| 300 | 0 | 0 | $opts{'payload'} // "" |
| 301 | 0 | 0 | $opts{'headers'} // {} |
| 306 | 0 | 0 | $ph->{'Accept'} ||= "*/*" |
| 325 | 0 | 0 | $ph->{$key} // "" |
| 424 | 0 | 0 | $uri->path_query || '/' |
| 425 | 0 | 0 | $opts{'host'} // "" |
| 432 | 0 | 0 | $uri->path_query || '/' |
| 491 | 0 | 0 | $socket->timeout // 15 |
| 537 | 0 | 0 | $hdr{'transfer-encoding'} || '' |
| 654 | 3 | 0 | $fp // "" |
| 712 | 1 | 0 | $timeout // 10 |
| 797 | 1 | 0 | $max // 5 |
| line | l | !l&&r | !l&&!r | condition |
|---|---|---|---|---|
| 47 | 1 | 30 | 0 | $opts{'user_agent'} // 'LightTCP::SSLclient/' . $VERSION |
| 106 | 0 | 0 | 0 | $!{'EAGAIN'} or $!{'EWOULDBLOCK'} |
| 305 | 0 | 0 | 0 | $ph->{'Host'} ||= $host |
| 307 | 0 | 0 | 0 | $ph->{'User-Agent'} ||= $self->{'user_agent'} |
| 308 | 0 | 0 | 0 | $ph->{'Connection'} ||= $self->{'keep_alive'} ? "keep-alive" : "close" |
| 447 | 0 | 0 | 0 | $code eq 301 or $code eq 302 |
| 631 | 0 | 0 | 0 | $trailing eq "\r\n" or $trailing eq "\n" |