Created
June 23, 2014 13:31
-
-
Save lyoshenka/1772ab97306bf861731e to your computer and use it in GitHub Desktop.
One-liner to create a self-signed SSL cert
This file contains 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
#!/bin/bash | |
# http://stackoverflow.com/questions/10175812/how-to-build-a-self-signed-certificate-with-openssl | |
openssl req -x509 -newkey rsa:2048 -keyout key.pem -out cert.pem -days 10000 | |
# if you don't want a password for your cert | |
openssl genrsa -out key.pem 4096 && openssl req -x509 -new -nodes -key key.pem -out cert.pem -days 10000 -subj "/CN=DOMAIN" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment