Limited certificate path validation only? are extensions accounted for?
Nobody has claimed this yet.
Assessment
- Difficulty
- 5/5
- Estimated time
- Over a week
- Newbie friendliness
- 25/100
Research direction
Start by reading the cited sections of validate.py and path.py, then compare their certificate-path handling with the documented validation scope and the referenced InhibitAnyPolicy behavior. Determine which extensions are intended to be supported and whether the documentation accurately states that scope; done requires an agreed validation or documentation plan.
Written by the indexing model from the issue text.
Description
There are many valid/standard extensions that apply to the scope of 'Validate the certificate path'
It appears key usage and basic verification (i.e. OpenSSL only validates hostname, expiry, and root trust) are only considered for Valid certificate path in this library, It does not seem that it is respecting extensions that should also apply.
The simplest example I can think of is the InhibitAnyPolicy because you state it is not done:
# Steps 1 d-f
# We do not use initial-explicit-policy, initial-any-policy-inhibit or
# initial-policy-mapping-inhibit, so they are all set to the path length + 1
But it is just a fairly straight forward counter i.e. https://cryptography.io/en/latest/x509/reference/#cryptography.x509.InhibitAnyPolicy
The inhibit anyPolicy extension indicates that the special OID ANY_POLICY, is not considered an explicit match for other CertificatePolicies except when it appears in an intermediate self-issued CA certificate. The value indicates the number of additional non-self-issued certificates that may appear in the path before ANY_POLICY is no longer permitted. For example, a value of one indicates that ANY_POLICY may be processed in certificates issued by the subject of this certificate, but not in additional certificates in the path.
So there must be some reasoning to just set it to path +1 and not use it? There are a few more comments that have some inherent rationale that is not documented, this one stood out to me but I see others and all really should have the rationale explained in the documentation because the documentation leads us to believe all relevant (i.e. critical extension) checks are performed
The next one that comes to mind that is fairly straight forward to write about is;
subjectKeyIdentifier of the root CA cert should match the authorityKeyIdentifier of the next cert in the chain, and so-on. And I believe this is not taken care of in this library, which is an assumption because I've tried using self-signed.badssl.com which has neither of these and the chain was seemingly able to be validated (not throwing exceptions with missing subjectKeyIdentifier or authorityKeyIdentifier), albeit self-signed so not in any root CA store and ultimately reported invalid.
Does this library aim to properly and completely 'Validate the certificate path'? Or is it only accounting for basic OpenSSL verification + key usages? If it is not aiming or already actually applying complete 'Validate the certificate path' as it claims, you might want to consider updating the docs and main message you're project is stating.
Maybe 'limited certificate path validation, and aim to eventually be a complete certificate path validation solution for python'' would be more accurate?
- Dominant language
- Python
- Stars
- 117
- Forks
- 37
- PR merge metrics
- No merged PRs in 30d
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from wbond/certvalidator
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
wbond/certvalidator#46 ·
-
Difficulty 1/5 1-3 hours Newbie friendliness 65/100
wbond/certvalidator#44 ·
-
Difficulty 1/5 Under an hour Newbie friendliness 65/100
wbond/certvalidator#22 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
wbond/certvalidator#11 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
wbond/certvalidator#56 · 1 comment ·
All issues in wbond/certvalidator
Similar issues
-
bug: conversation context selects the oldest thread messages instead of recent repliesPossibly taken @BLVCK-MAMBA-6 claimed this today. Openbug enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
AOSSIE-Org/SkillBot#74 ·
Maintainers usually reply within 1 day
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
bad-antics/lateralus-lang#1438 ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 77/100
Maintainers usually reply within 1 day
-
area: control app
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
glossyio/traffic-monitor#415 ·
Maintainers usually reply within 1 day
-
apply_matrix_rect takes 6-9% of extract_text timePossibly taken @g4lb claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 65/100
pdfminer/pdfminer.six#1333 ·
Maintainers usually reply within 1 day