Created
June 15, 2011 08:34
-
-
Save chrisglass/1026704 to your computer and use it in GitHub Desktop.
Generate a self-signed SSL certificate for use with Nginx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# generate super secret private key | |
# (not really, this key and the certificate are "throwaway" items) | |
openssl genrsa -des3 -out ssl.key 1024 | |
# generate the self-signed certificate | |
openssl req -new -x509 -nodes -sha1 -days 365 -key ssl.key -out ssl.crt | |
# create decrypted version of key so that nginx can be started without a passphrase | |
openssl rsa -in ssl.key -out ssl.key.insecure | |
chmod 600 ssl.key.insecure |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment