
Writing new private key to '/etc/easy-rsa/pki/easy-rsa-10170.VLZsfK/tmp.4TRoOP' Nopass disables the use of passphrase in the certificates. When the command runs, you will be prompted to enter the CA key passphrase create above. To generate a certificate and private key for the OpenVPN server, run the command below cd /etc/easy-rsa. Generate OpenVPN Server Certificate and Key It then stores the DH parameters on the /etc/easy-rsa/pki/dh.pem file. The command will take sometime to complete. While within the same Easy-RSA directory as in above, execute the command below to generate Diffie-Hellman key file that can be used for key exchange during the TLS handshake with connecting clients./easyrsa gen-dh Your new CA certificate file for publishing is at: If you enter '.', the field will be left blank.Ĭommon Name (eg: your user, host, or server name) :Kifarunix-demo CAĬA creation complete and you may now import and sign cert requests. There are quite a few fields but you can leave some blankįor some fields there will be a default value, What you are about to enter is what is called a Distinguished Name or a DN. You are about to be asked to enter information that will be incorporated Generating RSA private key, 2048 bit long modulus (2 primes) This will prompt you for the CA key passphrase and the server common name. Next, generate the CA certificate and key that will be used to sign certificates by running the commands below within the Easy-RSA directory above./easyrsa build-ca Your newly created PKI dir is: /etc/easy-rsa/pki Generate the Certificate Authority (CA) Certificate and Key Sample command output init-pki complete you may now create a CA or requests. Once the scripts are in place, navigate to the directory and initialize the PKI. mkdir /etc/easy-rsa cp -air /usr/share/easy-rsa/3/* /etc/easy-rsa/ To ensure that Easy-RSA any configuration made is not overwritten in case of an upgrade, copy the scripts to a different directory, preferably under /etc directory. The Easy-RSA scripts are installed under the /usr/share/easy-rsa directory. Initialize the PKIĮasy-RSA is used for PKI management. If possible, you should create the PKI on a separate server running OpenVPN for security purposes. The first step in setting up an OpenVPN server is to create a PKI which consists of public and private keys for the OpenVPN server and connecting clients and a master Certificate Authority certificate and private key for signing the OpenVPN server and client certificates. dnf install easy-rsa Create OpenVPN Public Key Infrastructure Dnf install openvpn Install Easy-RSA CA Utility on Rocky Linux 8Įasy-RSA package is a shell based CA utility that is used to generate SSL key-pairs that is used to secure VPN connections.
