line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Crypt::Perl::X509::Extension::tlsFeature; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
798
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
31
|
|
4
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
40
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
=encoding utf-8 |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
=head1 NAME |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
Crypt::Perl::X509::Extension::tlsFeature |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
=head1 SYNOPSIS |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
my $usage_obj = Crypt::Perl::X509::Extension::tlsFeature->new( 5 ); |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=head1 SEE ALSO |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
L |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=cut |
21
|
|
|
|
|
|
|
|
22
|
1
|
|
|
1
|
|
6
|
use parent qw( Crypt::Perl::X509::Extension ); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
9
|
|
23
|
|
|
|
|
|
|
|
24
|
1
|
|
|
1
|
|
67
|
use constant OID => '1.3.6.1.5.5.7.1.24'; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
64
|
|
25
|
|
|
|
|
|
|
|
26
|
1
|
|
|
1
|
|
5
|
use constant CRITICAL => 0; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
47
|
|
27
|
|
|
|
|
|
|
|
28
|
1
|
|
|
1
|
|
8
|
use constant ASN1 => <
|
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
48
|
|
29
|
|
|
|
|
|
|
tlsFeature ::= SEQUENCE OF INTEGER |
30
|
|
|
|
|
|
|
END |
31
|
|
|
|
|
|
|
|
32
|
1
|
|
|
1
|
|
5
|
use Crypt::Perl::X (); |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
208
|
|
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
#OpenSSL crypto/x509v3/v3_tlsf.c |
35
|
|
|
|
|
|
|
my %values = ( |
36
|
|
|
|
|
|
|
status_request => 5, |
37
|
|
|
|
|
|
|
status_request_v2 => 17, |
38
|
|
|
|
|
|
|
); |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
sub new { |
41
|
6
|
|
|
6
|
0
|
31
|
my ($class, @strs) = @_; |
42
|
|
|
|
|
|
|
|
43
|
6
|
|
|
|
|
38
|
my @ints; |
44
|
6
|
|
|
|
|
36
|
for my $v (@strs) { |
45
|
6
|
50
|
|
|
|
37
|
if (!$values{$v}) { |
46
|
0
|
|
|
|
|
0
|
die Crypt::Perl::X::create('Generic', "Unknown TLS feature string: ā$vā"); |
47
|
|
|
|
|
|
|
} |
48
|
|
|
|
|
|
|
|
49
|
6
|
|
|
|
|
21
|
push @ints, $values{$v}; |
50
|
|
|
|
|
|
|
} |
51
|
|
|
|
|
|
|
|
52
|
6
|
|
|
|
|
46
|
return bless \@ints, $class; |
53
|
|
|
|
|
|
|
} |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
sub _encode_params { |
56
|
6
|
|
|
6
|
|
38
|
my ($self) = @_; |
57
|
|
|
|
|
|
|
|
58
|
6
|
|
|
|
|
35
|
return [ @$self ]; |
59
|
|
|
|
|
|
|
} |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
1; |