Apche ssl is not working
- by user1703321
I have configure virtual host on 80 and 443 port(Centos 5.6 and apache 2.2.3), following is the sample, i have wrote the configuration in same order
Listen 80
Listen 443
NameVirtualHost *:80
NameVirtualHost *:443
<VirtualHost *:80>
ServerAdmin [email protected]
ServerName www.abc.be
ServerAlias abc.be
.
.
</VirtualHost>
<VirtualHost *:80>
ServerAdmin [email protected]
ServerName www.abc.fr
ServerAlias abc.fr
.
.
</VirtualHost>
then i have define 443
<VirtualHost *:443>
ServerAdmin [email protected]
ServerName www.abc.be
ServerAlias abc.be
.
.
SSLEngine on
SSLCertificateFile /etc/ssl/private/abc.be.crt
SSLCertificateKeyFile /etc/ssl/private/abc.be.key
SSLCertificateChainFile /etc/ssl/private/gd_bundle_be.crt
</VirtualHost>
<VirtualHost *:443>
ServerAdmin [email protected]
ServerName www.abc.fr
ServerAlias abc.fr
.
.
SSLEngine on
SSLCertificateFile /etc/ssl/private/abc.fr.crt
SSLCertificateKeyFile /etc/ssl/private/abc.fr.key
SSLCertificateChainFile /etc/ssl/private/gd_bundle_fr.crt
</VirtualHost>
First ssl certificate for abc.be is working fine, but 2nd domian abc.fr still load first ssl.
following the output of apachictl -s
VirtualHost configuration:
wildcard NameVirtualHosts and _default_ servers:
*:443 is a NameVirtualHost
default server www.abc.be (/etc/httpd/conf/httpd.conf:1071)
port 443 namevhost www.abc.fr (/etc/httpd/conf/httpd.conf:1071)
Thanks