mirror of
https://github.com/ansible-collections/community.crypto.git
synced 2026-04-26 00:16:28 +00:00
openssl_csr: handle missing basic constraint (#180)
* openssl_csr: handle missing basic constraint * openssl_csr: condense missing basic constraint check As suggested by felixfontein * add changelog fragment * Update changelogs/fragments/179-openssl-csr-basic-constraint.yml Co-authored-by: Felix Fontein <felix@fontein.de>
This commit is contained in:
@@ -626,9 +626,9 @@ class CertificateSigningRequestCryptographyBackend(CertificateSigningRequestBack
|
||||
return False
|
||||
# Check criticality
|
||||
if self.basicConstraints:
|
||||
if bc_ext.critical != self.basicConstraints_critical:
|
||||
return False
|
||||
return True
|
||||
return bc_ext is not None and bc_ext.critical == self.basicConstraints_critical
|
||||
else:
|
||||
return bc_ext is None
|
||||
|
||||
def _check_ocspMustStaple(extensions):
|
||||
try:
|
||||
|
||||
Reference in New Issue
Block a user