Last updated:2021-03-15 15:35:05
This document describes how to install a certificate on an Apache server.
Save the above .key file, server.crt, and ca.crt to the conf folder in the Apache installation directory.
Modify the httpd.conf file in the conf folder:
a. Open the httpd.conf file and locate the following line:
#LoadModule ssl_module modules/mod_ssl.so
b. Delete the comment sign (#) at the beginning.
c. Save and close the file.
Modify the ssl.conf file in the conf folder:
a. Open the ssl.conf file and search for LoadModule ssl_module to locate the following lines:
#LoadModule ssl_module modules/mod_ssl.so
#Include conf/extra/httpd_ssl.conf
b. Delete the comment sign (#) at the beginning of each line.
c. Save and close the file.
Modify the httpd-ssl.conf file in the conf/extra folder or the ssl.conf file in the conf folder:
a. Open the httpd-ssl.conf or ssl.conf file.
b. Add or edit the following lines between <VirtualHost *:443> and </VirtualHost>:
SSLProtocol all -SSLv2 -SSLv3 # It is recommended that you use the up-to-date OpenSSL version 1.0.0, 1.0.1, or 1.0.2.
SSLHonorCipherOrder on
SSLCipherSuite HIGH:!RC4:!MD5:!aNULL:!eNULL:!NULL:!DH:!EDH:!EXP:+MEDIUM
SSLCertificateFile conf/server.crt # Set the server certificate path.
SSLCertificateKeyFile conf/server.key # Set the private key path for the server certificate.
#SSLCertificateChainFile conf/ca.crt # Delete the comment sign (#) at the beginning and set the CA certificate path.
c. Save and close the file.
Go to the bin directory in the Apache installation directory and execute the following commands to restart Apache:
./apachectl -k stop
./apachectl -k start
Use HTTPS to access your website. You can enter “https://Domain name” in a browser. If the address bar displays the security lock icon, the certificate has been installed correctly.
Did you find the above information helpful?
Please give us your feedback.
Thank you for your feedback.