httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Florent Georges <>
Subject [users@httpd] Name virtual hosts and HTTPS
Date Sat, 21 Nov 2009 16:54:38 GMT

  I have one server one which I run two virtual hosts, say site1
and site2.  They run very well for HTTP stuff for months.  Site1
has also HTTPS access configured.  I am trying to add HTTPS
support for site2 as well.  So I created a new SSL certificate,
and added a new file in sites-available/:

    > cat /etc/apache2/sites-available/site1-https
    NameVirtualHost *:443
    <VirtualHost *:443>
        SSLEngine on
        SSLCertificateFile site.crt
        SSLCertificateKeyFile site1.key
        DocumentRoot /var/site1/htsdocs/

    > cat /etc/apache2/sites-available/site2-https
    NameVirtualHost *:443
    <VirtualHost *:443>
        SSLEngine on
        SSLCertificateFile site2.crt
        SSLCertificateKeyFile site2.key
        DocumentRoot /var/site2/htsdocs/

and enabled the second HTTPS web site with a2ensite.

  The problem is when I try to access site1 over HTTPS, it
provides me the certificate for site2...

  I double-checked the documentation with my very low Apache
skills, but did not found anything about that problem.  Did I
miss something?


Florent Georges


The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:> for more info.
To unsubscribe, e-mail:
   "   from the digest:
For additional commands, e-mail:

View raw message