Skip to content

Instantly share code, notes, and snippets.

@deed02392
Created July 21, 2017 13:39
Show Gist options
  • Save deed02392/dd1715ba9050dc00ac717b825eb1ada5 to your computer and use it in GitHub Desktop.
Save deed02392/dd1715ba9050dc00ac717b825eb1ada5 to your computer and use it in GitHub Desktop.
OpenSSL cert request magic file
openssl req -new -sha256 -nodes -out \*.your-new-domain.com.csr -newkey rsa:2048 -keyout \*.your-new-domain.com.key -config <(
cat <<-EOF
[req]
default_bits = 2048
prompt = no
default_md = sha256
req_extensions = req_ext
distinguished_name = dn
[ dn ]
C=US
ST=New York
L=Rochester
O=End Point
OU=Testing Domain
emailAddress=your-administrative-address@your-awesome-existing-domain.com
CN = www.your-new-domain.com
[ req_ext ]
subjectAltName = @alt_names
[ alt_names ]
DNS.1 = your-new-domain.com
DNS.2 = www.your-new-domain.com
EOF
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment