Basic Constraints path_length can be None

Bug #1825013 reported by Richard Vernon
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cursive
New
Undecided
Unassigned

Bug Description

"env/lib/python3.6/site-packages/cursive/certificate_utils.py", line 344, in verify
    if constraints.path_length < chain_length:
TypeError: '<' not supported between instances of 'NoneType' and 'int'

From https://cryptography.io/en/latest/x509/reference/?highlight=path_length#cryptography.x509.BasicConstraints.path_length

> This attribute only has meaning if ca is true. If ca is true then a path length of None means there’s no restriction on the number of subordinate CAs in the certificate chain.

The comparison needs a None check as well.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.