mirror of
https://github.com/certbot/certbot.git
synced 2026-06-09 08:42:57 -04:00
Add CN to subject
This will add the first domain as the Common Name (CN) in the subject.
This commit is contained in:
parent
e9050f1a3c
commit
dd433df514
1 changed files with 5 additions and 1 deletions
|
|
@ -88,7 +88,11 @@ def make_csr(
|
||||||
|
|
||||||
builder = (
|
builder = (
|
||||||
x509.CertificateSigningRequestBuilder()
|
x509.CertificateSigningRequestBuilder()
|
||||||
.subject_name(x509.Name([]))
|
.subject_name(
|
||||||
|
x509.Name([
|
||||||
|
x509.NameAttribute(x509.oid.NameOID.COMMON_NAME, domains[0])
|
||||||
|
])
|
||||||
|
)
|
||||||
.add_extension(
|
.add_extension(
|
||||||
x509.SubjectAlternativeName(
|
x509.SubjectAlternativeName(
|
||||||
[x509.DNSName(d) for d in domains]
|
[x509.DNSName(d) for d in domains]
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue