Skip to content

Instantly share code, notes, and snippets.

@terefang
Created March 1, 2021 09:19
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save terefang/8adc205fced98b8668d063defa3040cf to your computer and use it in GitHub Desktop.
Save terefang/8adc205fced98b8668d063defa3040cf to your computer and use it in GitHub Desktop.
cert-howto
https://github.com/terefang/shellutils/blob/master/CERTIFICATE_HOWTO.md
Windows: ftp://ftp.gnutls.org/gcrypt/gnutls/w32
csr.tmpl
-----
# X.509 Certificate options
# The common name of the certificate owner.
#C = <two-letter-country-code>
country = <two-letter-country-code>
#ST = <state-or-province>
state = "<state-or-province>"
#L = <city> O = <company-name>
locality = "<city>"
organization = "<company-name>"
#OU = MyDivision
unit = "MyDivision"
#CN = FQDN-of-Cisco-DNA-Centeron-GUI-port
cn = "FQDN-of-Cisco-DNA-Centeron-GUI-port"
#emailAddress = responsible-user@mycompany.tld
#dn = "cn = Nikos,st = New\, Something,C=GR,surName=Mavrogiannopoulos,2.5.4.9=Arkadias"
# X.509 v3 extensions
#[alt_names]
#DNS.1 = FQDN-of-Cisco-DNA-Center-on-GUI-port
#DNS.2 = FQDN-of-Cisco-DNA-Center-on-enterprise-port
#DNS.3 = pnpserver.DomainAssignedByDHCPDuringPnP.tld
#IP.1 = Enterprise port IP node #1
#IP.2 = Enterprise port IP node #2
#IP.3 = Enterprise port IP node #3
#IP.4 = Enterprise port VIP
#IP.5 = Cluster port IP node #1
#IP.6 = Cluster port IP node #2
#IP.7 = Cluster port IP node #3
#IP.8 = Cluster port VIP
#IP.9 = GUI port IP node #1
#IP.10 = GUI port IP node #2
#IP.11 = GUI port IP node #3
#IP.12 = GUI port VIP
#IP.13 = Cloud port IP node #1
#IP.14 = Cloud port IP node #2
#IP.15 = Cloud port IP node #3
#IP.16 = Cloud port VIP
dns_name = "FQDN-of-Cisco-DNA-Center-on-GUI-port"
dns_name = "FQDN-of-Cisco-DNA-Center-on-enterprise-port"
dns_name = "pnpserver.DomainAssignedByDHCPDuringPnP.tld"
ip_address = "Enterprise port IP node #1"
ip_address = "Enterprise port IP node #2"
#basicConstraints = CA:FALSE
#ca
#keyUsage = nonRepudiation, digitalSignature, keyEncipherment
signing_key
encryption_key
code_signing_key
time_stamping_key
#extendedKeyUsage=serverAuth,clientAuth
tls_www_client
tls_www_server
-----
@terefang
Copy link
Author

terefang commented Mar 1, 2021

certtool -p --bits 4096 --outfile csr.key

@terefang
Copy link
Author

terefang commented Mar 1, 2021

certtool -q --template csr.tmpl --load-privkey csr.key > csr.pem

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment