mirror of
https://github.com/phpseclib/phpseclib.git
synced 2024-11-16 02:07:09 +00:00
X509: serial numbers are biginteger's
This commit is contained in:
parent
247e969366
commit
36e9992508
@ -2201,7 +2201,7 @@ class File_X509
|
|||||||
case !is_array($authorityKey):
|
case !is_array($authorityKey):
|
||||||
case !$subjectKeyID:
|
case !$subjectKeyID:
|
||||||
case isset($authorityKey['keyIdentifier']) && $authorityKey['keyIdentifier'] === $subjectKeyID:
|
case isset($authorityKey['keyIdentifier']) && $authorityKey['keyIdentifier'] === $subjectKeyID:
|
||||||
if (is_array($authorityKey) && isset($authorityKey['authorityCertSerialNumber']) && $authorityKey['authorityCertSerialNumber'] != $ca['tbsCertificate']['serialNumber']) {
|
if (is_array($authorityKey) && isset($authorityKey['authorityCertSerialNumber']) && !$authorityKey['authorityCertSerialNumber']->equals($ca['tbsCertificate']['serialNumber'])) {
|
||||||
break 2; // serial mismatch - check other ca
|
break 2; // serial mismatch - check other ca
|
||||||
}
|
}
|
||||||
$signingCert = $ca; // working cert
|
$signingCert = $ca; // working cert
|
||||||
@ -2251,7 +2251,7 @@ class File_X509
|
|||||||
case !is_array($authorityKey):
|
case !is_array($authorityKey):
|
||||||
case !$subjectKeyID:
|
case !$subjectKeyID:
|
||||||
case isset($authorityKey['keyIdentifier']) && $authorityKey['keyIdentifier'] === $subjectKeyID:
|
case isset($authorityKey['keyIdentifier']) && $authorityKey['keyIdentifier'] === $subjectKeyID:
|
||||||
if (is_array($authorityKey) && isset($authorityKey['authorityCertSerialNumber']) && $authorityKey['authorityCertSerialNumber'] != $ca['tbsCertificate']['serialNumber']) {
|
if (is_array($authorityKey) && isset($authorityKey['authorityCertSerialNumber']) && !$authorityKey['authorityCertSerialNumber']->equals($ca['tbsCertificate']['serialNumber'])) {
|
||||||
break 2; // serial mismatch - check other ca
|
break 2; // serial mismatch - check other ca
|
||||||
}
|
}
|
||||||
$signingCert = $ca; // working cert
|
$signingCert = $ca; // working cert
|
||||||
|
Loading…
Reference in New Issue
Block a user