Differences between revisions 1 and 2
Revision 1 as of 2021-05-10 23:29:24
Size: 754
Editor: PieterSmit
Comment:
Revision 2 as of 2021-05-10 23:36:34
Size: 744
Editor: PieterSmit
Comment:
Deletions are marked like this. Additions are marked like this.
Line 33: Line 33:
openssl req -new -sha256 -nodes -out ${name}.csr -newkey rsa:2048 -keyout ${name}_pvt.key -config <( cat <csr_details>.txt ) openssl req -new -sha256 -nodes -out ${name}.csr -newkey rsa:2048 -keyout ${name}_pvt.key -config <( cat ${name}.txt )
Line 35: Line 35:

Linux/OpenSSL/CertificateRequest

  1. Create a csr_request.txt file with all the ssl parameters e.g.

    [req]
    default_bits = 2048
    prompt = no
    default_md = sha256
    req_extensions = req_ext
    distinguished_name = dn
    
    [ dn ]
    C=NZ
    ST=Auckland
    L=Auckland
    O=Mycompany
    OU=ICT
    emailAddress=ICT@gmail.com
    CN=testserver.test.net.nz
    
    [ req_ext ]
    subjectAltName = @alt_names
    
    [ alt_names ]
    # First DNS.1 entry must match CN above.
    DNS.1 = testserver.test.net.nz
    DNS.2 = www.test.net.nz
    DNS.3 = smtp.test.net.nz
  2. Generate the CSR using openssl config file above

    export name=<certName>
    openssl req -new -sha256 -nodes -out ${name}.csr -newkey rsa:2048 -keyout ${name}_pvt.key -config <( cat ${name}.txt )

Linux/OpenSSL/CertificateRequest (last edited 2021-05-10 23:36:34 by PieterSmit)