Merge branch '1.0' into 2.0

* 1.0:
  X509: set one more parameter to null
  X509: set another parameters field to null
This commit is contained in:
Andreas Fischer 2015-06-30 12:27:06 +02:00
commit 483c253879
2 changed files with 5 additions and 0 deletions

View File

@ -1491,6 +1491,9 @@ class X509
it seems like perhaps the ASN.1 description ought not say the parameters field is OPTIONAL, but whatever.
*/
$cert['tbsCertificate']['subjectPublicKeyInfo']['algorithm']['parameters'] = null;
// https://tools.ietf.org/html/rfc3279#section-2.2.1
$cert['signatureAlgorithm']['parameters'] = null;
$cert['tbsCertificate']['signature']['parameters'] = null;
}
}

View File

@ -140,6 +140,8 @@ aBtsWpliLSex/HHhtRW9AkBGcq67zKmEpJ9kXcYLEjJii3flFS+Ct/rNm+Hhm1l7
$cert = $x509->loadX509($cert);
$this->assertArrayHasKey('parameters', $cert['tbsCertificate']['subjectPublicKeyInfo']['algorithm']);
$this->assertArrayHasKey('parameters', $cert['signatureAlgorithm']);
$this->assertArrayHasKey('parameters', $cert['tbsCertificate']['signature']);
}
private function _encodeOID($oid)