Chat With Us
We are here for you!
Talk to a fellow human.
The location and name of the config file can vary from server to server - especially if you use 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/. For a comprehensive listing of default installation layouts for Apache HTTPD on various operating systems and distributions, see Httpd Wiki - DistrosDefaultLayout.
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/vhosts.d/, /etc/httpd/sites/, or in a file called httpd-ssl.conf.
One way to locate the SSL Configuration on Linux distributions is to search using grep, as shown in the example below.
Type the following command:
grep -i -r "SSLCertificateFile" /etc/httpd/
Where "/etc/httpd/" is the base directory for your Apache installation.
If you need your site to be accessible through both secure (https) and non-secure (http) connections:
You need a virtual host for each type of connection. One for port 80 and the other for port 443. Make a copy of the existing non-secure virtual host and configure it for SSL as described in step 4.
If you only need your site to be accessed securely:
Configure the existing virtual host for SSL as described in step 4.
<VirtualHost 192.168.0.1:<strong>443</strong>> DocumentRoot /var/www/html2 ServerName www.yourdomain.com <strong>SSLEngine on SSLCertificateFile /path/to/your_domain_name.crt SSLCertificateKeyFile /path/to/server.key SSLCertificateChainFile /path/to/CACompany<strong>ECCSecureServerCA.crt</strong></strong> </VirtualHost>
This file should be your ECC SSL Certificate file (e.g. your_domain_name.crt).
This file should be the key file generated in step 2 of the Apache: Create Your ECC CSR (Certificate Signing Request)instruction.
This file should be the ECC intermediate certificate file.
Note: If the SSLCertificateChainFile directive does not work, try using the SSLCACertificateFile directive instead.
Because Apache will not start again if your config files have syntax errors, you should check your Apache config files for any errors before restarting.
<strong>apachectl stop</strong> <strong>apachectl start</strong>