@@ 190-205 (lines=16) @@ | ||
187 | * |
|
188 | * @return Sequence |
|
189 | */ |
|
190 | public function toASN1() { |
|
191 | $elements = array(); |
|
192 | if (isset($this->_baseCertificateID)) { |
|
193 | $elements[] = new ImplicitlyTaggedType(0, |
|
194 | $this->_baseCertificateID->toASN1()); |
|
195 | } |
|
196 | if (isset($this->_entityName)) { |
|
197 | $elements[] = new ImplicitlyTaggedType(1, |
|
198 | $this->_entityName->toASN1()); |
|
199 | } |
|
200 | if (isset($this->_objectDigestInfo)) { |
|
201 | $elements[] = new ImplicitlyTaggedType(2, |
|
202 | $this->_objectDigestInfo->toASN1()); |
|
203 | } |
|
204 | return new Sequence(...$elements); |
|
205 | } |
|
206 | } |
|
207 |
@@ 121-135 (lines=15) @@ | ||
118 | * @see \X509\AttributeCertificate\AttCertIssuer::ASN1() |
|
119 | * @return ImplicitlyTaggedType Tagged Sequence |
|
120 | */ |
|
121 | public function toASN1() { |
|
122 | $elements = array(); |
|
123 | if (isset($this->_issuerName)) { |
|
124 | $elements[] = $this->_issuerName->toASN1(); |
|
125 | } |
|
126 | if (isset($this->_baseCertificateID)) { |
|
127 | $elements[] = new ImplicitlyTaggedType(0, |
|
128 | $this->_baseCertificateID->toASN1()); |
|
129 | } |
|
130 | if (isset($this->_objectDigestInfo)) { |
|
131 | $elements[] = new ImplicitlyTaggedType(1, |
|
132 | $this->_objectDigestInfo->toASN1()); |
|
133 | } |
|
134 | return new ImplicitlyTaggedType(0, new Sequence(...$elements)); |
|
135 | } |
|
136 | } |
|
137 |
@@ 204-217 (lines=14) @@ | ||
201 | * |
|
202 | * @return Sequence |
|
203 | */ |
|
204 | public function toASN1() { |
|
205 | $elements = array(); |
|
206 | if (isset($this->_distributionPoint)) { |
|
207 | $elements[] = new ExplicitlyTaggedType(0, |
|
208 | $this->_distributionPoint->toASN1()); |
|
209 | } |
|
210 | if (isset($this->_reasons)) { |
|
211 | $elements[] = new ImplicitlyTaggedType(1, $this->_reasons->toASN1()); |
|
212 | } |
|
213 | if (isset($this->_issuer)) { |
|
214 | $elements[] = new ImplicitlyTaggedType(2, $this->_issuer->toASN1()); |
|
215 | } |
|
216 | return new Sequence(...$elements); |
|
217 | } |
|
218 | } |
|
219 |