Sonntag, 7. Juni 2015

Quickly generate self-signed SSL certificate and key

How to get an SSL certificate which you can use for e.g. local testing

openssl req -x509 -newkey rsa:2048 -keyout key.pem -out cert.pem -days 365

Generates key.pem and cert.pem.

For localhost testing enter for the server name (FQDN): localhost

Since this is a self-signed certificate the browser will show a warning. If you don't want warnings you can get a free certificate from e.g http://www.startssl.com/


Keine Kommentare:

Kommentar veröffentlichen