1. Copy the certificate files to the server
There should be 3 SSL files:
- DigiCertCA.crt – This will be your chain file.
Note: Make them readable by root only to increase security.
2. Find the Apache configuration file (httpd.conf) you need to edit.
- The name and location and name of the configuration file can vary from server to server—mainly if you’re using a special interface to manage your server configuration.
- Apache’s main configuration file is typically named httpd.conf or apache2.conf. Possible locations for this file include /etc/httpd/ or /etc/apache2/.
- Often, the SSL certificate configuration is located in a <VirtualHost> block in a different configuration file. The configuration files may be under a directory like /etc/httpd/, /etc/apache2/. In this directory, you need to find the conf file of the site for the site www.uksoccershop.com it will be uksoccershop.com.conf. You will find the <VirtualHost> tag in this file. In case the file uksoccershop.com.conf is not present you can use the common file httpd.conf or apache2.conf
3. Identify the SSL <VirtualHost> block you need to configure.
Below is a very simple example of a virtual host configured for SSL. The parts listed in blue are the parts you must add for SSL configuration.
4. Adjust the file names to match your certificate files.
SSLCertificateFile is your DigiCert certificate file (e.g., your_domain_name.crt).
SSLCertificateKeyFile is the .key file generated when you created the CSR (e.g., your_private.key).
SSLCertificateChainFile is the DigiCert intermediate certificate file (e.g., DigiCertCA.crt)
Note: If the SSLCertificateChainFile directive does not work, try using the SSLCACertificateFile directive instead.
Recommended Blog: How to install MySQL on Windows and Linux Systems?
5. Test your Apache configuration file before restarting.
As a best practice, check your Apache configuration file for any errors before restarting Apache.
Caution: Apache won’t start again if your configuration files have syntax errors.
Run the following command to test your configuration file (on some systems, it’s apache2ctl):
6. In case of no error please restart apache using the below command
service apache2 restart
After restarting apache2, you can check whether your SSL is set up correctly or not using https://www.sslshopper.com/ssl-checker.html. In the above screenshot, you have to verify that the arrow should be green like above between server and chain. If there is no issue then your SSL is set up correctly.
Recommended Blog: SSL Certificate Installation on IIS
In case of an issue while implementing the code, feel free to reach out to us at support@Knowband.com. Also, Knowband offers eCommerce store plugins at the best price. We offer the smartest solution for online platforms including PrestaShop, OpenCart, Magento 2 and WooCommerce.