Repository navigation
Add testcases exercising general CRL structure - #577
Conversation
|
For most of these tests, I had to be careful not to conflate a failure to interpret the CRL and a failure to build the chain. Consider a CRL containing an uninterpretable critical extension and an entry revoking the leaf certificate. For this case, a conformant verifier would fail because the CRL is invalid, while a non-conformant verifier would fail to build the chain as it interprets the CRL and revokes the certificate. I worked around this for these tests, but there may be something we can do in limbo to better support verifying CRL validation behavior. |
55cadbf to
997c361
Compare
|
@woodruffw can I get a review on this when you're available? |
997c361 to
6b1bdb1
Compare
|
These look generally OK to me, but I just wanted to jump in here to say that "CRL with duplicate revoked entry serial numbers" should be slotted into RFC5280 tests, as this is completely valid (and intentionally used) in non-RFC5280 X.509 PKI profiles. |
|
Also, and maybe I'm just not interpreting the test cases properly, but the descriptions for extensions don't make clear whether the test is about |
Only the last two tests are applicable to |
08851a6 to
59ab528
Compare
| revoked: list[x509.RevokedCertificate] = [], | ||
| aki: _Extension[x509.AuthorityKeyIdentifier] | Literal[True] | None = True, | ||
| crl_number: _Extension[x509.CRLNumber] | Literal[True] | None = True, | ||
| extra_extension: _Extension[x509.ExtensionType] | None = None, |
There was a problem hiding this comment.
This seems fine, but maybe it can be extra_extensions for generality?
There was a problem hiding this comment.
agree! we'll have to change the identical surface in the cert builders as well; probably deserves a separate PR
a75269e to
0055618
Compare
0055618 to
3e463d5
Compare
Here's a tranche of CRL testcases as outlined in pyca/cryptography#10393 (comment):