You state that your vhost config looks like:

<IfDefine SSL_DEFAULT_VHOST>

<IfModule ssl_module>

<VirtualHost *:80>
        .
        .
        .

if you want https to work, I believe your virtual host command should 
read:

<VirtualHost *:443>

I assume that in some other VirtualHost block, you already have a 
<VirtualHost *:80>.

BTW, you can't use NameVirtualHosts (at least not more then 1) with SSL.



Please respond to users@httpd.apache.org

To:     users@httpd.apache.org
cc:      (bcc: Dan Mitton/YD/RWDOE)
Subject:        Re: [EMAIL PROTECTED] httpd2 vhost & ssl configuration problem
LSN: Not Relevant
User Filed as: Not a Record

Do you have a line like this outside your virtual host scope
NameVirtualHost *:443

On Wed, 2008-02-20 at 08:09 +1300, PingBad wrote:
> On Wednesday 20 February 2008 00:10, pat wrote:
> 
> > Hello
> 
> >
> 
> > I have a problem with the apache2 configuration if I want to combine
> 
> > vhost and ssl settings.
> 
> > My apache opts: APACHE2_OPTS="-D DEFAULT_VHOST -D INFO -D LANGUAGE
> -D
> 
> > SSL -D SSL_DEFAULT_VHOST -D PHP5 -D PERL -D PYTHON -D SUEXEC"
> 
> >
> 
> > This is my vhost config:
> 
> > <IfDefine SSL_DEFAULT_VHOST>
> 
> > <IfModule ssl_module>
> 
> > <VirtualHost *:80>
> 
> >
> 
> > ServerName host.company.com
> 
> >
> 
> > DirectoryIndex index.php index.html
> 
> > DocumentRoot "/var/www/localhost/htdocs/host-company-com"
> 
> > ServerAlias host.company.com *.host.company.com
> 
> > ErrorLog /var/log/apache2/vhosts/error_log
> 
> > CustomLog /var/log/apache2/vhosts/access_log common
> 
> >
> 
> > <Directory "/var/www/localhost/htdocs/host-company-com">
> 
> > SSLRequireSSL
> 
> > Options Indexes FollowSymLinks
> 
> > AllowOverride None
> 
> > Order allow,deny
> 
> > Allow from all
> 
> > </Directory>
> 
> > </VirtualHost>
> 
> >
> 
> > Now my problem is that if I connect to http://host.company.com works
> 
> > (the content from /var/www/localhost/htdocs/host-company-com is
> shown),
> 
> > but if I connect to https://host.company.com it doesn't work
> correctly
> 
> > and the content from /var/www/localhost/htdocs/ (default
> DocumentRoot)
> 
> > is shown.
> 
> > Why? I want to have ssl support for my vhost "host.company.com" but
> 
> > apache forwards to the wrong DocumentRoot.
> 
> > Does anyone have an idea, what the problem is?
> 
> >
> 
> > Thank you and best regards,
> 
> > pat
> 
> >
> 
> >
> ---------------------------------------------------------------------
> 
> > The official User-To-User support forum of the Apache HTTP Server
> Project.
> 
> > See <URL:http://httpd.apache.org/userslist.html> for more info.
> 
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> 
> > " from the digest: [EMAIL PROTECTED]
> 
> > For additional commands, e-mail: [EMAIL PROTECTED]
> 
> Did you setup a VirtualHost for port 443?
> 
> <VirtualHost *:443>
> 
> ServerName host.company.com
> 
> DirectoryIndex index.php index.html
> 
> DocumentRoot "/var/www/localhost/htdocs/host-company-com"
> 
> ServerAlias host.company.com *.host.company.com
> 
> ErrorLog /var/log/apache2/vhosts/error_log
> 
> CustomLog /var/log/apache2/vhosts/access_log common
> 
> <Directory "/var/www/localhost/htdocs/host-company-com">
> 
> SSLRequireSSL
> 
> Options Indexes FollowSymLinks
> 
> AllowOverride None
> 
> Order allow,deny
> 
> Allow from all
> 
> </Directory>
> 
> </VirtualHost>
> 
> HTTP and HTTPS use 2 different ports.
> 
> -- 
> 
> PingBad,
> 
> IRC Fanatic
> 


CONFIDENTIALITY NOTICE:  This electronic mail message and any attachment 
hereto may contain confidential information of Meyer Sound Laboratories, 
Incorporated and is intended for the personal and confidential use of the 
designated recipient(s) only.  If you are not the intended recipient (or 
responsible for delivering the message to the intended recipient), you 
have received this message in error and any review, distribution, or 
copying of this message or any attachment hereto is prohibited.  If you 
have received this message in error, please promptly notify the sender and 
permanently delete it from your computer.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
   "   from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: [EMAIL PROTECTED]
   "   from the digest: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to