Chrome: How to install self-signed SSL certificates
Often, during the development of a website on our local machine (localhost) or on our remote private server, we do not have an SSL certificate issued by a trusted certification authority, and we are forced to configure the webserver with a self-signed certificate.
In this case, while browsers such as Firefox allow you to add an exception, even permanently, to the site in question, opening that website in Chrome will produce each time a notice of this type (NET::ERR_CERT_AUTHORITY_INVALID):
This warning, moreover, will imply that you won’t be able to save login data of your website, as Chrome does not save forms information for websites having an unsafe HTTPS connection.
To resolve this problem, you need to accomplish a very simple task: export the SSL certificate for the website in the appropriate format and install it as a trusted certificate.
To export the SSL certificate we’ll use Google Chrome.
Open Chrome and visit your website. You will get the above warning, click on “ADVANCED” and then on “Proceed to <domain name> (unsafe)”.
At this point, open Chrome Developer tools by hitting F12 key and go to “Security” tab.
Click on “View certificate“, go to “Details” tab and click on “Copy to File…”.
Hit “Next” and select “Cryptographic Message Syntax Standard – PKCS #7 Certificates (.P7B)“, then “Next” again.
Click “Browse…” and save certificate to a location on your PC (ie: Desktop) by clicking “Next”.
Finally, click “Finish”.
In the next page we’ll see how to import the certificate.