@@ -80,7 +80,7 @@ discard block |
||
80 | 80 | if ($seq->hasTagged(0)) { |
81 | 81 | $attr_seq = $seq->getTagged(0)->implicit(Element::TYPE_SEQUENCE); |
82 | 82 | $permitted = array_map( |
83 | - function (Element $el) { |
|
83 | + function(Element $el) { |
|
84 | 84 | return $el->expectType(Element::TYPE_OBJECT_IDENTIFIER)->oid(); |
85 | 85 | }, $attr_seq->elements()); |
86 | 86 | $idx++; |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | if ($seq->hasTagged(1)) { |
89 | 89 | $attr_seq = $seq->getTagged(1)->implicit(Element::TYPE_SEQUENCE); |
90 | 90 | $excluded = array_map( |
91 | - function (Element $el) { |
|
91 | + function(Element $el) { |
|
92 | 92 | return $el->expectType(Element::TYPE_OBJECT_IDENTIFIER)->oid(); |
93 | 93 | }, $attr_seq->elements()); |
94 | 94 | $idx++; |
@@ -183,14 +183,14 @@ discard block |
||
183 | 183 | } |
184 | 184 | if (isset($this->_permittedAttrs)) { |
185 | 185 | $oids = array_map( |
186 | - function ($oid) { |
|
186 | + function($oid) { |
|
187 | 187 | return new ObjectIdentifier($oid); |
188 | 188 | }, $this->_permittedAttrs); |
189 | 189 | $elements[] = new ImplicitlyTaggedType(0, new Sequence(...$oids)); |
190 | 190 | } |
191 | 191 | if (isset($this->_excludedAttrs)) { |
192 | 192 | $oids = array_map( |
193 | - function ($oid) { |
|
193 | + function($oid) { |
|
194 | 194 | return new ObjectIdentifier($oid); |
195 | 195 | }, $this->_excludedAttrs); |
196 | 196 | $elements[] = new ImplicitlyTaggedType(1, new Sequence(...$oids)); |
@@ -35,7 +35,7 @@ |
||
35 | 35 | */ |
36 | 36 | public static function fromPEMs(PEM ...$pems) { |
37 | 37 | $certs = array_map( |
38 | - function ($pem) { |
|
38 | + function($pem) { |
|
39 | 39 | return Certificate::fromPEM($pem); |
40 | 40 | }, $pems); |
41 | 41 | return new self(...$certs); |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | public function allOf($name) { |
71 | 71 | $oid = AttributeType::attrNameToOID($name); |
72 | 72 | $attrs = array_filter($this->_attributes, |
73 | - function (Attribute $attr) use ($oid) { |
|
73 | + function(Attribute $attr) use ($oid) { |
|
74 | 74 | return $attr->oid() == $oid; |
75 | 75 | }); |
76 | 76 | return array_values($attrs); |
@@ -110,7 +110,7 @@ discard block |
||
110 | 110 | public function withUnique(Attribute $attr) { |
111 | 111 | $obj = clone $this; |
112 | 112 | $obj->_attributes = array_filter($obj->_attributes, |
113 | - function (Attribute $a) use ($attr) { |
|
113 | + function(Attribute $a) use ($attr) { |
|
114 | 114 | return $a->oid() != $attr->oid(); |
115 | 115 | }); |
116 | 116 | $obj->_attributes[] = $attr; |
@@ -45,7 +45,7 @@ discard block |
||
45 | 45 | $paths = $this->_resolvePathsToTarget($target, $intermediate); |
46 | 46 | // map paths to CertificationPath objects |
47 | 47 | return array_map( |
48 | - function ($certs) { |
|
48 | + function($certs) { |
|
49 | 49 | return new CertificationPath(...$certs); |
50 | 50 | }, $paths); |
51 | 51 | } |
@@ -108,7 +108,7 @@ discard block |
||
108 | 108 | throw new PathBuildingException("No certification paths."); |
109 | 109 | } |
110 | 110 | usort($paths, |
111 | - function ($a, $b) { |
|
111 | + function($a, $b) { |
|
112 | 112 | return count($a) < count($b) ? -1 : 1; |
113 | 113 | }); |
114 | 114 | return reset($paths); |