line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Crypt::Perl::X509::InfoAccessBase; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
530
|
use strict; |
|
1
|
|
|
|
|
6
|
|
|
1
|
|
|
|
|
31
|
|
4
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
29
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
8
|
use parent qw( Crypt::Perl::X509::Extension ); |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
13
|
|
7
|
|
|
|
|
|
|
|
8
|
1
|
|
|
1
|
|
59
|
use Crypt::Perl::X509::GeneralName (); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
14
|
|
9
|
1
|
|
|
1
|
|
16
|
use Crypt::Perl::X (); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
56
|
|
10
|
|
|
|
|
|
|
|
11
|
1
|
|
|
1
|
|
8
|
use constant ASN1 => Crypt::Perl::X509::GeneralName::ASN1() . <
|
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
81
|
|
12
|
|
|
|
|
|
|
InfoAccess ::= SEQUENCE OF AccessDescription |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
AccessDescription ::= SEQUENCE { |
15
|
|
|
|
|
|
|
accessMethod OBJECT IDENTIFIER, |
16
|
|
|
|
|
|
|
accessLocation ANY -- GeneralName |
17
|
|
|
|
|
|
|
} |
18
|
|
|
|
|
|
|
END |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
use constant { |
21
|
1
|
|
|
|
|
307
|
asn1_macro => 'InfoAccess', |
22
|
|
|
|
|
|
|
CRITICAL => 0, |
23
|
1
|
|
|
1
|
|
7
|
}; |
|
1
|
|
|
|
|
2
|
|
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub new { |
26
|
12
|
|
|
12
|
0
|
81
|
my ($class, @accessDescrs) = @_; |
27
|
|
|
|
|
|
|
|
28
|
12
|
50
|
|
|
|
65
|
if (!@accessDescrs) { |
29
|
0
|
|
|
|
|
0
|
die Crypt::Perl::X::create('Generic', 'Need access descriptions!'); |
30
|
|
|
|
|
|
|
} |
31
|
|
|
|
|
|
|
|
32
|
12
|
|
|
|
|
80
|
return bless \@accessDescrs, $class; |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
sub _encode_params { |
36
|
12
|
|
|
12
|
|
107
|
my ($self) = @_; |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
my $data = [ |
39
|
|
|
|
|
|
|
map { |
40
|
12
|
50
|
|
|
|
87
|
$self->can("OID_$_->[0]") or die( Crypt::Perl::X::create('Generic', "Unknown method: “$_->[0]”") ); |
|
24
|
|
|
|
|
1739
|
|
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
{ |
43
|
|
|
|
|
|
|
accessMethod => $self->can("OID_$_->[0]")->(), |
44
|
24
|
|
|
|
|
141
|
accessLocation => Crypt::Perl::X509::GeneralName->new( @{$_}[1,2] )->encode(), |
|
24
|
|
|
|
|
113
|
|
45
|
|
|
|
|
|
|
} |
46
|
|
|
|
|
|
|
} @$self, |
47
|
|
|
|
|
|
|
]; |
48
|
|
|
|
|
|
|
|
49
|
12
|
|
|
|
|
1336
|
return $data; |
50
|
|
|
|
|
|
|
} |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
1; |