line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Crypt::Perl::ASN1::Encodee; |
2
|
|
|
|
|
|
|
|
3
|
5
|
|
|
5
|
|
2074
|
use strict; |
|
5
|
|
|
|
|
10
|
|
|
5
|
|
|
|
|
121
|
|
4
|
5
|
|
|
5
|
|
22
|
use warnings; |
|
5
|
|
|
|
|
8
|
|
|
5
|
|
|
|
|
108
|
|
5
|
|
|
|
|
|
|
|
6
|
5
|
|
|
5
|
|
1080
|
use Crypt::Perl::ASN1 (); |
|
5
|
|
|
|
|
13
|
|
|
5
|
|
|
|
|
103
|
|
7
|
5
|
|
|
5
|
|
29
|
use Crypt::Perl::X (); |
|
5
|
|
|
|
|
9
|
|
|
5
|
|
|
|
|
695
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub asn1_macro { |
10
|
467
|
|
|
467
|
0
|
965
|
my ($self_or_class) = @_; |
11
|
|
|
|
|
|
|
|
12
|
467
|
|
33
|
|
|
1272
|
my $class = ref($self_or_class) || $self_or_class; |
13
|
|
|
|
|
|
|
|
14
|
467
|
50
|
|
|
|
2938
|
$class =~ m<.+::(.+)> or die Crypt::Perl::X::create('Generic', "Invalid class: “$class”"); |
15
|
|
|
|
|
|
|
|
16
|
467
|
|
|
|
|
2092
|
return $1; |
17
|
|
|
|
|
|
|
} |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
sub encode { |
20
|
499
|
|
|
499
|
0
|
2014
|
my ($self) = @_; |
21
|
|
|
|
|
|
|
|
22
|
499
|
|
|
|
|
1655
|
my $asn1 = Crypt::Perl::ASN1->new(); |
23
|
499
|
|
|
|
|
25630
|
$asn1 = $asn1->prepare( $self->ASN1() )->find( $self->asn1_macro() ); |
24
|
|
|
|
|
|
|
|
25
|
499
|
|
|
|
|
10116
|
return $asn1->encode( $self->_encode_params() ); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
1; |