Skip to content

Instantly share code, notes, and snippets.

@alexamiryan
Created January 19, 2010 15:51
Show Gist options
  • Save alexamiryan/281019 to your computer and use it in GitHub Desktop.
Save alexamiryan/281019 to your computer and use it in GitHub Desktop.
Create SSL certificate
#!/bin/sh
openssl genrsa -out client.key 1024
openssl req -new -key client.key -out client.csr
openssl x509 -req -days 365 -CA ca.crt -CAkey ca.key -CAcreateserial -in client.csr -out client.crt
openssl pkcs12 -export -clcerts -in client.crt -inkey client.key -out client.p12
rm -f client.crt client.csr client.key
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment