SSL + name-based virtual host

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I am an apache newbie so I apologize if my question seems silly..
I am having some problems enabling SSL on our web server.

We have one IP address for the server and 3 name-based virtual hosts.
=============================
NameVirtualHost OUR_IP_ADDRESS:80

<VirtualHost OUR_IP_ADDRESS:80>
ServerName    www.NAME1.com
 DocumentRoot  /var/www/html1
</VirtualHost>


<VirtualHost OUR_IP_ADDRESS:80>
 ServerName    www.NAME2.com
 DocumentRoot /var/www/html2
</VirtualHost>


<VirtualHost OUR_IP_ADDRESS:80>
 ServerName    fwww.NAME3.com
 DocumentRoot /var/www/html3
</VirtualHost>
=================================
We would like to enable SSL for www.NAME1.com or ALL of these virtual hosts.. (Really - we just want it to work in any fashion at this point!)
Now, according to <http://httpd.apache.org/docs/2.0/ssl/ssl_faq.html#vhosts2>, I have tried updating this to:
=============================
<IfModule mod_ssl.c>
    Include conf.d/ssl.conf
</IfModule>

/*......*/

NameVirtualHost OUR_IP_ADDRESS:80

<VirtualHost OUR_IP_ADDRESS:443>
ServerName    NAME1.com
 DocumentRoot  /var/www/html1
</VirtualHost>


<VirtualHost OUR_IP_ADDRESS:80>
 ServerName    NAME2.com
 DocumentRoot /var/www/html2
</VirtualHost>


<VirtualHost OUR_IP_ADDRESS:80>
 ServerName    NAME3.com
 DocumentRoot /var/www/html3
</VirtualHost>
=================================
where conf.d/ssl.conf file contains all the appropriate codes for enabling SSL - loading the module, certificate and key definitions, etc.
However, when I do this, http://www.NAME1.com will point to http://www.NAME2.com and https://www.NAME1.com does not work.
The certificate is issued to NAME1.com which is also the name of the server....

Any help would be greatly appreciated!!!
Are there any easy to follow guides on how to ssl enable name-based virtual hosts?

Thanks!
LK


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux