Created
February 16, 2018 18:57
-
-
Save hpherzog/2ee68d7105d36d1ae1f52a89ae3195ba to your computer and use it in GitHub Desktop.
Create self signed ssl certificate including subjectAltName
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
openssl req -x509 -nodes -days 730 -newkey rsa:2048 -keyout key.pem -out cert.pem -config openssl.conf -extensions 'v3_req' |
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
[req] | |
distinguished_name = req_distinguished_name | |
x509_extensions = v3_req | |
prompt = no | |
[req_distinguished_name] | |
C = DE | |
ST = Bundesland | |
L = Stadt | |
O = Firma | |
OU = Abteilung | |
CN = foo1 | |
[v3_req] | |
keyUsage = keyEncipherment, dataEncipherment | |
extendedKeyUsage = serverAuth | |
subjectAltName = @alt_names | |
[alt_names] | |
DNS.1 = foo1 | |
DNS.2 = foo2 | |
DNS.3 = localhost |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment