@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension\Target; |
6 | 6 |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension\Target; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension\Target; |
6 | 6 | |
@@ -41,7 +41,7 @@ discard block |
||
41 | 41 | public static function fromASN1(Sequence $seq): self |
42 | 42 | { |
43 | 43 | $targets = array_map( |
44 | - function (UnspecifiedType $el) { |
|
44 | + function(UnspecifiedType $el) { |
|
45 | 45 | return Target::fromASN1($el->asTagged()); |
46 | 46 | }, $seq->elements()); |
47 | 47 | return new self(...$targets); |
@@ -102,7 +102,7 @@ discard block |
||
102 | 102 | public function toASN1(): Sequence |
103 | 103 | { |
104 | 104 | $elements = array_map( |
105 | - function (Target $target) { |
|
105 | + function(Target $target) { |
|
106 | 106 | return $target->toASN1(); |
107 | 107 | }, $this->_targets); |
108 | 108 | return new Sequence(...$elements); |
@@ -141,7 +141,7 @@ discard block |
||
141 | 141 | { |
142 | 142 | return array_values( |
143 | 143 | array_filter($this->_targets, |
144 | - function (Target $target) use ($type) { |
|
144 | + function(Target $target) use ($type) { |
|
145 | 145 | return $target->type() == $type; |
146 | 146 | })); |
147 | 147 | } |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension\Target; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension; |
6 | 6 | |
@@ -134,7 +134,7 @@ discard block |
||
134 | 134 | protected static function _fromDER(string $data, bool $critical): Extension |
135 | 135 | { |
136 | 136 | $targets = array_map( |
137 | - function (UnspecifiedType $el) { |
|
137 | + function(UnspecifiedType $el) { |
|
138 | 138 | return Targets::fromASN1($el->asSequence()); |
139 | 139 | }, UnspecifiedType::fromDER($data)->asSequence()->elements()); |
140 | 140 | return new self($critical, ...$targets); |
@@ -146,7 +146,7 @@ discard block |
||
146 | 146 | protected function _valueASN1(): Element |
147 | 147 | { |
148 | 148 | $elements = array_map( |
149 | - function (Targets $targets) { |
|
149 | + function(Targets $targets) { |
|
150 | 150 | return $targets->toASN1(); |
151 | 151 | }, $this->_targets); |
152 | 152 | return new Sequence(...$elements); |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension; |
6 | 6 |
@@ -1,6 +1,6 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension; |
6 | 6 | |
@@ -174,7 +174,7 @@ discard block |
||
174 | 174 | $attr_seq = $seq->getTagged(0)->asImplicit(Element::TYPE_SEQUENCE) |
175 | 175 | ->asSequence(); |
176 | 176 | $permitted = array_map( |
177 | - function (UnspecifiedType $el) { |
|
177 | + function(UnspecifiedType $el) { |
|
178 | 178 | return $el->asObjectIdentifier()->oid(); |
179 | 179 | }, $attr_seq->elements()); |
180 | 180 | ++$idx; |
@@ -183,7 +183,7 @@ discard block |
||
183 | 183 | $attr_seq = $seq->getTagged(1)->asImplicit(Element::TYPE_SEQUENCE) |
184 | 184 | ->asSequence(); |
185 | 185 | $excluded = array_map( |
186 | - function (UnspecifiedType $el) { |
|
186 | + function(UnspecifiedType $el) { |
|
187 | 187 | return $el->asObjectIdentifier()->oid(); |
188 | 188 | }, $attr_seq->elements()); |
189 | 189 | ++$idx; |
@@ -205,14 +205,14 @@ discard block |
||
205 | 205 | } |
206 | 206 | if (isset($this->_permittedAttrs)) { |
207 | 207 | $oids = array_map( |
208 | - function ($oid) { |
|
208 | + function($oid) { |
|
209 | 209 | return new ObjectIdentifier($oid); |
210 | 210 | }, $this->_permittedAttrs); |
211 | 211 | $elements[] = new ImplicitlyTaggedType(0, new Sequence(...$oids)); |
212 | 212 | } |
213 | 213 | if (isset($this->_excludedAttrs)) { |
214 | 214 | $oids = array_map( |
215 | - function ($oid) { |
|
215 | + function($oid) { |
|
216 | 216 | return new ObjectIdentifier($oid); |
217 | 217 | }, $this->_excludedAttrs); |
218 | 218 | $elements[] = new ImplicitlyTaggedType(1, new Sequence(...$oids)); |
@@ -1,6 +1,6 @@ |
||
1 | 1 | <?php |
2 | 2 | |
3 | -declare(strict_types = 1); |
|
3 | +declare(strict_types=1); |
|
4 | 4 | |
5 | 5 | namespace Sop\X509\Certificate\Extension; |
6 | 6 |