line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::ACME2::HTTP::Response; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
11
|
use strict; |
|
2
|
|
|
|
|
2
|
|
|
2
|
|
|
|
|
43
|
|
4
|
2
|
|
|
2
|
|
7
|
use warnings; |
|
2
|
|
|
|
|
2
|
|
|
2
|
|
|
|
|
40
|
|
5
|
|
|
|
|
|
|
|
6
|
2
|
|
|
2
|
|
7
|
use parent qw( HTTP::Tiny::UA::Response ); |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
7
|
|
7
|
|
|
|
|
|
|
|
8
|
2
|
|
|
2
|
|
94
|
use JSON (); |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
30
|
|
9
|
|
|
|
|
|
|
|
10
|
2
|
|
|
2
|
|
9
|
use Net::ACME2::X (); |
|
2
|
|
|
|
|
2
|
|
|
2
|
|
|
|
|
254
|
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
sub die_because_unexpected { |
13
|
0
|
|
|
0
|
0
|
0
|
my ($self) = @_; |
14
|
|
|
|
|
|
|
|
15
|
0
|
|
|
|
|
0
|
die Net::ACME2::X->create( |
16
|
|
|
|
|
|
|
'UnexpectedResponse', |
17
|
|
|
|
|
|
|
{ |
18
|
|
|
|
|
|
|
uri => $self->url(), |
19
|
|
|
|
|
|
|
status => $self->status(), |
20
|
|
|
|
|
|
|
reason => $self->reason(), |
21
|
|
|
|
|
|
|
headers => $self->headers(), |
22
|
|
|
|
|
|
|
}, |
23
|
|
|
|
|
|
|
); |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
#Useful for everything but certificate issuance, apparently? |
27
|
|
|
|
|
|
|
sub content_struct { |
28
|
12
|
|
|
12
|
0
|
400
|
my ($self) = @_; |
29
|
|
|
|
|
|
|
|
30
|
12
|
|
33
|
|
|
160
|
my $json = ($self->{'_json'} ||= JSON->new()->allow_nonref()); |
31
|
|
|
|
|
|
|
|
32
|
12
|
|
|
|
|
212
|
return $json->decode( $self->content() ); |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
1; |