Basic SSL commands for OpenSSL

Basic SSL commands for OpenSSL 

1. Connect to your server via SSH.
2. To generate CSR via OpenSSL run the following command:
openssl req -out -new -newkey rsa:2048 -nodes -keyout

3. To generate CSR for existing key:
openssl req -out CSR.csr -key privateKey.key -new

4. To generate CSR for existing SSL:
openssl x509 -x509toreq -in certificate.crt -out CSR.csr -signkey privateKey.key

5. To check if SSL certificate matches with the private key.
SSL certification check:
openssl x509 -noout -modulus -in certificate.crt | openssl md5

Private key check:
openssl rsa -noout -modulus -in privateKey.key | openssl md5

Get information for CSR, SSL and private key.
SSL information: openssl x509 -in certificate.crt -text -noout
CSR info: openssl req -text -noout -verify -in CSR.csr
Private key info: openssl rsa -in privateKey.key -check

Was this article helpful?
1 out of 1 found this helpful

Have more questions? Contact our support instantly via Live Chat