solo/web/make_localhost_cert.sh
2018-09-10 18:22:14 -04:00

5 lines
385 B
Bash

# Run this to make cert you can import in chrome, then run localhost with HTTPS
openssl req -x509 -out localhost.crt -keyout localhost.key -newkey rsa:2048 -nodes -sha256 -subj '/CN=localhost' -extensions EXT -config <( \
printf "[dn]\nCN=localhost\n[req]\ndistinguished_name = dn\n[EXT]\nsubjectAltName=DNS:localhost\nkeyUsage=digitalSignature\nextendedKeyUsage=serverAuth")