Common openssl commands

By | 03/05/2015

# sha256 self signed certificate with new private key
openssl req -newkey rsa:2048 -keyout server.key -nodes -sha256 -x509 -new -days 3650 -out server.crt -subj '/C=DE/ST=Berlin/L=Berlin/O=Organization Name/OU=Department/CN=www.domain.de'

# sha256 self signed certificate with existing private key
openssl req -key server.key -sha256 -x509 -new -days 3650 -out server.crt -subj '/C=DE/ST=Berlin/L=Berlin/O=Organization Name/OU=Department/CN=www.domain.de'

# sha256 certificate request with existing private key
openssl req -key server.key -sha256 -new -out server.csr -subj '/C=DE/ST=Berlin/L=Berlin/O=Organization Name/OU=Department/CN=www.domain.de'

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.