Jason Parms

To complete SSL certificate installation on the Apache server, you need below 3 keys.

  1. SSLCertificateKeyFile: Server private key created with CSR key
  2. SSLCertificateFile: Your Certificate Issuer will provide domain certificate signed for your domain name only.
  3. SSLCertificateKeyFile: Publicly trusted SSL certificate issued by Certificate Authorities.

Installation Process…

  1. Download/copy SSL certificate code received from Certificate Issuer and save file as mydomain.crt
(-----BEGIN CERTIFICATE----- XXXXXXX -----END CERTIFICATE-----)
  1. Get certificate issuer intermediate and root certificates. Contact your ssl certificate issuer to get correct version. Save file as rootca.crt
  2. Upload both certificate files on server
    (/path/to/mydomain.crt and /path/to/rootca.crt)
  3. Login server and find Apache Configuration file (httpd.conf) to edit.
    General installation find apahce configuration files in /etc/httpd and the main configuration file is named as httpd.conf. You should edit
  1. Identify the <VirtualHost> block to configure ssl certificate. Below is very simple example of virtual host configuration.
<VirtualHost 192.168.0.1:443>
DocumentRoot /var/www/yourdomain
ServerName www.yourdomain.com
SSLEngine on
SSLCertificateChainFile /path/to/rootca.crt
SSLCertificateFile /path/to/mydomain.crt
SSLCertificateKeyFile /path/to/private.key
</VirtualHost>

You should configure a new virtual host for each new website and sub-domains.

  1. Command to test Apache config before restarting.
apachectlconfigtest
  1. Restart Apache service to activate SSL certificate installation changes. Command to restart Apache service.
apachectl stop
apachectl start

Related Article: