U should create three files:
Import certificate into Google Chrome (other browsers - try to figure it out on your own):
default-ssl, and replace the following lines:
SSLCertificateFile /etc/ssl/certs/ssl-cert-
snakeoil.pem
SSLCertificateKeyFile /etc/ssl/private/ssl-cert-
snakeoil.key
snakeoil.pem
SSLCertificateFile /etc/ssl/certs/ssl-cert.crt
#SSLCertificateKeyFile /etc/ssl/private/ssl-cert-
snakeoil.key
SSLCertificateKeyFile /etc/ssl/private/ssl-cert-
private.key
- a self-signed certificate file (ssl-cert.crt), which is used by Browser.
- a public key file(ssl-cert.pfx) with proof of identity for signed and/or encrypted message, which is used by Browser. The public key can be derived from its corresponding private key.
- a privet key file(ssl-cert-private.key), which is used by Apache.
Import certificate into Google Chrome (other browsers - try to figure it out on your own):
- Go to Preferences, click "Under the hood".
- Under HTTPS/SSL, click on "Manage Certificates".
- Click "Import..." and import your ssl-cert.pfx file. Your certificate should appear now in the list of "Your Certificates".
- Go to "Authorities", click "Import.." and import your ssl-cert.crt file. The name should now appear under the list of Authorities.
Configure Apache to work with SSL
- Execute:
sudo cp ssl-cert-private.key /etc/ssl/private/
sudo a2enmod ssl
sudo ln -s ../sites-available/default-ssl 000-default-ssl
- Edit /etc/apache2/sites-available/
snakeoil.pem
SSLCertificateKeyFile /etc/ssl/private/ssl-cert-
snakeoil.key
- With the following lines:
snakeoil.pem
SSLCertificateFile /etc/ssl/certs/ssl-cert.crt
#SSLCertificateKeyFile /etc/ssl/private/ssl-cert-
snakeoil.key
SSLCertificateKeyFile /etc/ssl/private/ssl-cert-
private.key
- Restart Apache by executing the following command:
Now when you access the website your certificate should be valid.
No comments:
Post a Comment