- Run this command to generate the key
openssl req \
-newkey rsa:2048 \
-x509 \
-nodes \
-keyout server.key \
-new \
-out server.crt \
-subj /CN=dev.mycompany.com \
-reqexts SAN \
-extensions SAN \
-config <(cat /System/Library/OpenSSL/openssl.cnf \
<(printf '[SAN]\nsubjectAltName=DNS:dev.mycompany.com')) \
-sha256 \
-days 3650
-
Open on the mac -> keychain Access.app
-
Drag your server.crt and drop inside access.app
-
Double click in the certificate and mark "Always trust"
-
Open your vhost and configure your SSLCertificateFile
SSLEngine on
SSLCipherSuite ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP:+eNULL
SSLCertificateFile "/etc/apache2/certs/server.crt"
SSLCertificateKeyFile "/etc/apache2/certs/server.key"
-
Restart your apache
-
In chrome go to development tools -> Application tab -> clear storage and "Clear site data"
-
Re-open your URL in chrome.