Issues (15)

src/structures/P7S.php (1 issue)

Labels
Severity
1
<?php
2
3
namespace vakata\asn1\structures;
4
5
use \vakata\asn1\ASN1;
0 ignored issues
show
The type \vakata\asn1\ASN1 was not found. Maybe you did not declare it correctly or list all dependencies?

The issue could also be caused by a filter entry in the build configuration. If the path has been excluded in your configuration, e.g. excluded_paths: ["lib/*"], you can move it to the dependency path list as follows:

filter:
    dependency_paths: ["lib/*"]

For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths

Loading history...
6
7
class P7S extends Structure
8
{
9
    public static function map()
10
    {
11
        return [
12
            'tag' => ASN1::TYPE_SEQUENCE,
13
            'children' => [
14
                'type' => [
15
                    'tag' => ASN1::TYPE_OBJECT_IDENTIFIER
16
                ],
17
                'data' => [
18
                    'name' => 0,
19
                    'tag' => ASN1::TYPE_SEQUENCE,
20
                    'implicit' => false,
21
                    'children' => [
22
                        'version' => [
23
                            'tag' => ASN1::TYPE_INTEGER
24
                        ],
25
                        'algos' => [
26
                            'tag' => ASN1::TYPE_SET,
27
                            'repeat' => Common::AlgorithmIdentifier(),
28
                        ],
29
                        'content' =>[
30
                            'tag' => ASN1::TYPE_SEQUENCE,
31
                            'children' => [
32
                                "type" => [
33
                                    'tag' => ASN1::TYPE_OBJECT_IDENTIFIER
34
                                ],
35
                                'data' => [ 'tag' => ASN1::TYPE_ANY_DER, 'optional' => true, 'name' => 0 ]
36
                            ]
37
                        ],
38
                        'certificates' => [
39
                            'tag' => ASN1::TYPE_SET,
40
                            'name' => 0,
41
                            'implicit' => true,
42
                            'optional' => true,
43
                            'repeat' => Certificate::map()
44
                        ],
45
                        'crls' => [
46
                            'tag' => ASN1::TYPE_SET,
47
                            'name' => 1,
48
                            'implicit' => true,
49
                            'optional' => true,
50
                            'repeat' => [
51
                                'tag' => ASN1::TYPE_ANY
52
                            ]
53
                        ],
54
                        'signerInfos' => [
55
                            'tag' => ASN1::TYPE_SET,
56
                            'repeat' => [
57
                                'tag' => ASN1::TYPE_SEQUENCE,
58
                                'children' => [
59
                                    'version' => [ 'tag' => ASN1::TYPE_INTEGER ],
60
                                    'sid' => [
61
                                        'tag' => ASN1::TYPE_SEQUENCE,
62
                                        'children' => [
63
                                            'issuer' => [ 'tag' => ASN1::TYPE_ANY ],
64
                                            'serial' => [ 'tag' => ASN1::TYPE_INTEGER, 'base' => 16 ]
65
                                        ]
66
                                    ],
67
                                    'digest_algo' => Common::AlgorithmIdentifier(),
68
                                    'signed' => [
69
                                        'name' => 0,
70
                                        'tag' => ASN1::TYPE_SET,
71
                                        'optional' => true,
72
                                        'implicit' => true,
73
                                        'repeat' => [
74
                                            'tag' => ASN1::TYPE_SEQUENCE,
75
                                            'children' => [
76
                                                "type" => [
77
                                                    'tag' => ASN1::TYPE_OBJECT_IDENTIFIER
78
                                                ],
79
                                                "data" => [
80
                                                    'tag' => ASN1::TYPE_SET,
81
                                                    'repeat' => [
82
                                                        'tag' => ASN1::TYPE_ANY_DER
83
                                                    ]
84
                                                ]
85
                                            ]
86
                                        ]
87
                                    ],
88
                                    'signature_algo' => Common::AlgorithmIdentifier(),
89
                                    'signature' => [ 'tag' => ASN1::TYPE_OCTET_STRING ],
90
                                    'unsigned' => [
91
                                        'name' => 1,
92
                                        'tag' => ASN1::TYPE_SET,
93
                                        'optional' => true,
94
                                        'implicit' => true,
95
                                        'repeat' => [
96
                                            'tag' => ASN1::TYPE_SEQUENCE,
97
                                            'children' => [
98
                                                "type" => [
99
                                                    'tag' => ASN1::TYPE_OBJECT_IDENTIFIER
100
                                                ],
101
                                                "data" => [
102
                                                    'tag' => ASN1::TYPE_SET,
103
                                                    'repeat' => [
104
                                                        'tag' => ASN1::TYPE_ANY_DER
105
                                                    ]
106
                                                ]
107
                                            ]
108
                                        ]
109
                                    ],
110
                                ]
111
                            ]
112
                        ]
113
                    ]
114
                ]
115
            ]
116
        ];
117
    }
118
}
119