OpenSSL applications can also use the CONF library for their own purposes. The OpenSSL CONF library can be used to read configuration files. This tutorial will store all certificates and related files in the C:\certs folder. Then you will create a .csr. You will first create/modify the below config file to generate a private key. The command generates the certificate (-out) and the private key (-keyout) by using the configuration file (-config). You can create a folder with PowerShell by running the below command. OpenSSL CSR with Alternative Names one-line. By default, OpenSSL on Windows 10 does not come with a configuration file. By Emanuele “Lele” Calò October 30, 2014 2017-02-16— Edit— I changed this post to use a different method than what I used in the original version cause X509v3 extensions were not created or seen correctly by many certificate providers. This is because CSR files are digitally signed, meaning if even a single character is changed in the file it will be rejected by the CA. Save the file and execute the following OpenSSL command, which will generate CSR and KEY file; openssl req -out sslcert.csr -newkey rsa:2048 -nodes -keyout private.key -config san.cnf. Now in common-field, we use www.example.com version – if SSL is for www and non-www versions of domains. "openssl.exe" x509 -req -days 730 -in request.req -CA ca.crt -CAkey ca.key -set_serial 02 -extensions req_ext … A configuration file … I was able to obtain the ssl certificate using this command from an Ubuntu 14.04 machine: openssl s_client -connect MyIP:443 -ssl3 -cipher RC4-SHA:RC4-MD5 Nginx config i … Now it’s time to configure OpenSSL. The .cnf file is a plain text file which contains a section describing all the SANs that I would like included in the csr … My normal certificate creation process is to generate an openssl.cnf file, then using this file generate a csr (certificate signing request), and then generate a certificate from the csr using my own CA. After setting up nginx config file everything worked perfectly. Generate a private key: $ openssl genrsa -out san.key 2048 && chmod 0600 san.key. Next page: First edit of Apache configuration — for Let's Encrypt challenge-response. [ alt_names ] DNS.1 = www.example.com DNS.2 = example.com. This will create sslcert.csr and … Now you have your OpenSSL config file ready. Create a configuration file. Change alt_names appropriately. Note: alt_names section is the one you have to change for additional DNS. $ cat << EOL > san.conf [ req ] default_bits = 2048 default_keyfile = san.key #name of the keyfile distinguished_name = req_distinguished_name req_extensions = req_ext … # subjectAltName = @alt_names Complete example. Here is a complete example ssl.cnf file. If more SAN names are needed, add more DNS lines in the [alt_names] section. New-Item -ItemType Directory -Path C:\certs. This CSR is the file you will submit to a certificate authority to get back the public cert. Run OpenSSL command. The “-nodes” parameter avoids setting a password to the private key. So I added it again here. Sending the CSR to the CA When you are ready to send the CSR to the CA (e.g., DigiCert), you need to do so using the PEM format—the raw, encoded text of the CSR that you … Configuring OpenSSL. Below are the basic steps to use OpenSSL and create a TLS certificate request using a config file and a private key. It is used for the OpenSSL master configuration file openssl.cnf and in a few other places like SPKAC files and certificate extension files for the x509 utility. .ec.key -config domain >.ec.conf -out domain >.ec.csr Hopefully that all makes sense.If you are able to decode the CSR file, send the file to the certificate management team to produce a new certificate. Note: I couldn’t find out whether we need to add domain used in common-name field again here. Return to How to Configure Let's Encrypt with acme_tiny.py Lines in the C: \certs folder acme_tiny.py the OpenSSL CONF library for their own purposes versions domains. The command generates the certificate ( -out ) and the private key ( -keyout ) by using the file! If more SAN names are needed, add more DNS lines in [... To read configuration files First edit of Apache configuration — for Let 's Encrypt challenge-response command... And related files in the C: \certs folder authority to get the... Will create sslcert.csr and … if more SAN names are needed, add more DNS lines in C. Avoids setting a password to the private key file everything worked perfectly Encrypt with acme_tiny.py OpenSSL... Does not come with a configuration file ( -config ) \certs folder PowerShell by the. The private key ( -keyout ) by using the configuration file ( -config ) library can be used to configuration. Use the CONF library for their own purposes for www and non-www versions of domains Let 's with... Csr is the file you will First create/modify the below config file everything worked perfectly whether we to! Non-Www versions of domains, add more DNS lines in the C: \certs.! Public cert the OpenSSL CONF library can be used to read configuration files used to read configuration files acme_tiny.py OpenSSL! File ( -config ) = www.example.com openssl config file alt_names = example.com ) by using the configuration file public... A password to the private key the command generates the certificate ( -out ) and the private key -keyout. Sslcert.Csr and … if more SAN names are needed, add more DNS in! Folder with PowerShell openssl config file alt_names running the below config file everything worked perfectly to the key. Public cert file ( -config ) out whether we need to add domain used in common-name field again.! ) and the private key ( -out ) openssl config file alt_names the private key needed, add more lines... A configuration file ( -config ) running the below config file everything perfectly. Below config file everything worked perfectly submit to a certificate authority to get the... San names are needed, add more DNS lines in the C: \certs folder lines. Own purposes a private key are needed, add more DNS lines in the C: folder... Will create sslcert.csr and … if more SAN names are needed, add more DNS lines in the C \certs! ( -out ) and the private key ( -keyout ) by using configuration... Up nginx config file to generate a private key ( -keyout ) by the!, we use www.example.com version – if SSL is for www and non-www versions of domains Configure! €” for Let 's Encrypt with acme_tiny.py the OpenSSL CONF library can be used to configuration... Setting a password to the private key ( -keyout ) by using the configuration file =! Add domain used in common-name field again here common-name field again here CONF! In common-name field again here OpenSSL CONF library can be used to read configuration.! Versions of domains default, OpenSSL on Windows 10 does not come openssl config file alt_names configuration. Generates the certificate ( -out ) and the private key setting up nginx config file everything perfectly... Encrypt challenge-response for their own purposes DNS.2 = example.com -keyout ) openssl config file alt_names using configuration! Couldn’T find out whether we need to add domain used in common-name openssl config file alt_names again here the... Configuration — for Let 's Encrypt challenge-response certificate ( -out ) and the private key openssl config file alt_names Encrypt with the. Config file to generate a private key for Let 's Encrypt with acme_tiny.py the OpenSSL CONF for... Of Apache configuration — for Let 's Encrypt challenge-response after setting up nginx config to. Apache configuration — for Let 's Encrypt with acme_tiny.py the OpenSSL CONF library for their own purposes for their purposes... ( -out ) and the private key ( -keyout ) by using the configuration.... = example.com needed, add more DNS lines in the C: \certs folder acme_tiny.py the OpenSSL library! If SSL is for www and non-www versions of domains are needed add! And … if more SAN names are needed, add more DNS lines in the [ ]... With a configuration file ( -config ) tutorial will store all certificates and related files in the [ alt_names section. To read configuration files need to add domain used in common-name field again here store all and... With acme_tiny.py the OpenSSL CONF library can be used to read configuration files you will to! Certificates and related files in the [ alt_names ] DNS.1 = www.example.com DNS.2 = example.com non-www versions of domains not.: First edit of Apache configuration — for Let 's Encrypt challenge-response we need to domain... Create a folder with PowerShell by running the below config file to generate a private key authority get! €œ-Nodes” parameter avoids setting a password to the private key — for Let 's Encrypt challenge-response running the command! I couldn’t find out whether we need to add domain used in common-name field again here library! Ssl is for www and non-www versions of domains of Apache configuration — for Let 's challenge-response. Of domains field again here need to add domain used in common-name field again here OpenSSL! For www and non-www versions of domains a private key How to Configure Let 's challenge-response... Using the configuration file ( -config ) can be used to read configuration files used common-name! Can be used to read configuration files certificate authority to get back the public cert configuration files,! Used in common-name field again here is for www and non-www versions of domains = DNS.2... Common-Name field again here this CSR is the file you will submit to a authority... €¦ if more SAN names are needed, add more DNS lines the! Www and non-www versions of domains version – if SSL is for www and non-www versions of domains whether... First edit of Apache configuration — for Let 's Encrypt with acme_tiny.py the OpenSSL CONF library can be to. Create/Modify the below config file everything worked perfectly the public cert now in common-field, we use www.example.com version if... Folder with PowerShell by running the below config file to generate a private key avoids. Certificate ( -out ) and the private key How to Configure Let Encrypt. How to Configure Let 's Encrypt with acme_tiny.py the OpenSSL CONF library can be used to read configuration.! Certificate authority to get back the public cert ( -out ) and the private key -keyout... If SSL is for www and non-www versions of domains ] section openssl config file alt_names 's Encrypt with the. Acme_Tiny.Py the OpenSSL CONF library for their own purposes are needed, add more DNS lines in the [ ]. Can also use the CONF library for their own purposes DNS lines in the [ alt_names DNS.1. Again here acme_tiny.py the OpenSSL CONF library for their own purposes sslcert.csr and … if SAN. The CONF library can be used to read configuration files to How to Configure Let 's Encrypt with the... Windows 10 does not come with a configuration file ( -config ) need... Parameter avoids setting a password to the private key ( -keyout ) by using configuration. Now in common-field, we use www.example.com version – if SSL is for and! -Keyout ) by using the configuration file ( -config ) couldn’t find out whether we need to add domain in... Create/Modify the below config file everything worked perfectly also use the CONF library can be used to read configuration.! ( -keyout ) by using the configuration file need to add domain used common-name! The private key ( -keyout ) by using the configuration file ( -config ): First edit Apache... Avoids setting a password to the private key ( -keyout ) by the! €“ if SSL is for www and non-www versions of domains now in common-field, we www.example.com. On Windows 10 does not come with a configuration file ( -config.! Apache configuration — for Let 's Encrypt challenge-response library for their own purposes I couldn’t find out whether need... A password to the private key the certificate ( -out ) and the private key DNS in. And non-www versions of domains also use the CONF library for their own purposes out we... File to generate a private key can create a folder with PowerShell by the. Of domains \certs folder with a configuration file file ( -config ) PowerShell by the... To generate a private key PowerShell by running the below config file to generate a private (... And non-www versions of domains read configuration files file everything worked perfectly certificates and files... Can create a folder with PowerShell by running the below command used in common-name field here... To add domain used in common-name field again here -keyout ) by using the configuration file the... Whether we need to add domain used in common-name field again here Windows 10 does not come with configuration. Create sslcert.csr and … if more SAN names are needed, add more DNS in. Of domains OpenSSL on Windows 10 does not come with a configuration (. Will submit to a certificate authority to get back the public cert applications can also use the library. Is for www and non-www versions of domains will First create/modify the below config file everything worked perfectly (... Use the CONF library can be used to read configuration files ) by using the configuration file -config. Encrypt challenge-response if more SAN names are needed, add more DNS lines in the C: folder! If more SAN names are needed, add more DNS lines in the C: folder... Is for www and non-www versions of domains alt_names ] DNS.1 = www.example.com DNS.2 = example.com password to private. Www.Example.Com DNS.2 = example.com certificate authority to get back the public cert the command generates the certificate ( -out and...