Useful site with SSL commands, CSR and certificate decoder:

Display certificate request:

openssl req -noout -text -in /etc/apache2/ssl/server2016.csr

Display to whom it was issued from PEM file:

openssl x509 -noout -in imapd.pem -subject

Display certificate:

openssl x509 -noout -text -in /etc/apache2/ssl/server2016.crt

Create key:

openssl genrsa 2048 >

Create certificate request from existing key (SHA2):

openssl req -new -key -sha256 -out server2016.csr

Show public key information:

openssl rsa -in -pubout

Test SSL connection and print out SSL certificate:

openssl s_client -connect

Connect to SMTP server with STARTTLS:

openssl s_client -connect --starttls smtp

For more information, check the OpenSSL Command-Line HOWTO.