Fix: San values #2921

Not sure is it correct solution
This commit is contained in:
e11it 2020-03-03 21:45:33 +03:00 committed by GitHub
parent 462099d906
commit 27a86f5c18
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -146,6 +146,8 @@ class CertificateInputSchema(CertificateCreationSchema):
data["extensions"]["subAltNames"] = {"names": []}
elif not data["extensions"]["subAltNames"].get("names"):
data["extensions"]["subAltNames"]["names"] = []
if not data["extensions"]["subAltNames"]["names"]:
data["extensions"]["subAltNames"]["names"] += csr_sans
return missing.convert_validity_years(data)