SSL site loads regardless of URL??
SSL site loads regardless of URL??
am 17.06.2002 09:24:01 von david
Hi,
I have several virtually hosted web sites and only one site that is
configured for SSL on my server.
The issue is if someone uses https instead of http the certificated site
pages load regardless of the url ie
http://stats.domain1.co.nz loads pages from ../domain1 which is correct.
https://stats.domain1.co.nz loads pages from ../donations, and the url
remains https://stats.domain1.co.nz
I assume I have a misconfigured .conf file?
How can I resolve this, do I need to specify port 80 on the http sites
or do I need to multi home the server with a unique IP for the SSL site?
Thanks
-David.
Below is an illustration of the httpd.conf.
ServerName www.donations.org.nz
DocumentRoot /var/www/html/donations
ErrorLog /var/log/httpd/donations-error_log
TransferLog /var/log/httpd/donations-access_log
NameVirtualHost 219.88.240.45
ServerName stats.domain1.co.nz
DocumentRoot /var/www/html/domain1
ErrorLog /var/log/httpd/domain1-error_log
TransferLog /var/log/httpd/domain1-access_log
ServerName stats.domain2.co.nz
DocumentRoot /var/www/html/domain2
ErrorLog /var/log/httpd/domain2-error_log
TransferLog /var/log/httpd/domain2-access_log
ServerName stats.domain3.co.nz
DocumentRoot /var/www/html/domain3
ErrorLog /var/log/httpd/domain3-error_log
TransferLog /var/log/httpd/domain3-access_log
____________________________________________________________ __________
Apache Interface to OpenSSL (mod_ssl) www.modssl.org
User Support Mailing List modssl-users@modssl.org
Automated List Manager majordomo@modssl.org
Re: SSL site loads regardless of URL??
am 17.06.2002 09:52:02 von Peter Viertel
Virtual hosts are defined agains the listening addresses you have for
your host:
Not sure what some of the host names resolve to but assuming 192.168
addresses are the actual ip of your host, and the other ip is the nat
outside address for your host then the config would look like this:
ServerName www.donations.org.nz
DocumentRoot /var/www/html/donations
ErrorLog /var/log/httpd/donations-error_log
TransferLog /var/log/httpd/donations-access_log
NameVirtualHost 192.168.1.9:80
ServerName stats.domain1.co.nz
DocumentRoot /var/www/html/domain1
ErrorLog /var/log/httpd/domain1-error_log
TransferLog /var/log/httpd/domain1-access_log
ServerName stats.domain2.co.nz
DocumentRoot /var/www/html/domain2
ErrorLog /var/log/httpd/domain2-error_log
TransferLog /var/log/httpd/domain2-access_log
ServerName stats.domain3.co.nz
DocumentRoot /var/www/html/domain3
ErrorLog /var/log/httpd/domain3-error_log
TransferLog /var/log/httpd/domain3-access_log
David wrote:
> Hi,
>
> I have several virtually hosted web sites and only one site that is
> configured for SSL on my server.
>
> The issue is if someone uses https instead of http the certificated site
> pages load regardless of the url ie
>
> http://stats.domain1.co.nz loads pages from ../domain1 which is correct.
>
> https://stats.domain1.co.nz loads pages from ../donations, and the url
> remains https://stats.domain1.co.nz
>
> I assume I have a misconfigured .conf file?
>
> How can I resolve this, do I need to specify port 80 on the http sites
> or do I need to multi home the server with a unique IP for the SSL site?
>
>
> Thanks
>
> -David.
>
>
> Below is an illustration of the httpd.conf.
>
>
> ServerName www.donations.org.nz
> DocumentRoot /var/www/html/donations
> ErrorLog /var/log/httpd/donations-error_log
> TransferLog /var/log/httpd/donations-access_log
>
>
> NameVirtualHost 219.88.240.45
>
>
> ServerName stats.domain1.co.nz
> DocumentRoot /var/www/html/domain1
> ErrorLog /var/log/httpd/domain1-error_log
> TransferLog /var/log/httpd/domain1-access_log
>
>
>
> ServerName stats.domain2.co.nz
> DocumentRoot /var/www/html/domain2
> ErrorLog /var/log/httpd/domain2-error_log
> TransferLog /var/log/httpd/domain2-access_log
>
>
>
> ServerName stats.domain3.co.nz
> DocumentRoot /var/www/html/domain3
> ErrorLog /var/log/httpd/domain3-error_log
> TransferLog /var/log/httpd/domain3-access_log
>
>
>
>
>
> ____________________________________________________________ __________
> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
> User Support Mailing List modssl-users@modssl.org
> Automated List Manager majordomo@modssl.org
____________________________________________________________ __________
Apache Interface to OpenSSL (mod_ssl) www.modssl.org
User Support Mailing List modssl-users@modssl.org
Automated List Manager majordomo@modssl.org
Re: SSL site loads regardless of URL??
am 18.06.2002 01:54:15 von david
Thanks for the comments Peter,
The server has real world IP's. I just used 192.. for the example. Which
probably was dumb as it clouded the issue.
-David
Peter Viertel wrote:
> Virtual hosts are defined agains the listening addresses you have for
> your host:
>
> Not sure what some of the host names resolve to but assuming 192.168
> addresses are the actual ip of your host, and the other ip is the nat
> outside address for your host then the config would look like this:
>
>
> ServerName www.donations.org.nz
> DocumentRoot /var/www/html/donations
> ErrorLog /var/log/httpd/donations-error_log
> TransferLog /var/log/httpd/donations-access_log
>
>
> NameVirtualHost 192.168.1.9:80
>
>
> ServerName stats.domain1.co.nz
> DocumentRoot /var/www/html/domain1
> ErrorLog /var/log/httpd/domain1-error_log
> TransferLog /var/log/httpd/domain1-access_log
>
>
>
> ServerName stats.domain2.co.nz
> DocumentRoot /var/www/html/domain2
> ErrorLog /var/log/httpd/domain2-error_log
> TransferLog /var/log/httpd/domain2-access_log
>
>
>
> ServerName stats.domain3.co.nz
> DocumentRoot /var/www/html/domain3
> ErrorLog /var/log/httpd/domain3-error_log
> TransferLog /var/log/httpd/domain3-access_log
>
>
>
> David wrote:
>
>> Hi,
>>
>> I have several virtually hosted web sites and only one site that is
>> configured for SSL on my server.
>>
>> The issue is if someone uses https instead of http the certificated site
>> pages load regardless of the url ie
>>
>> http://stats.domain1.co.nz loads pages from ../domain1 which is correct.
>>
>> https://stats.domain1.co.nz loads pages from ../donations, and the url
>> remains https://stats.domain1.co.nz
>>
>> I assume I have a misconfigured .conf file?
>>
>> How can I resolve this, do I need to specify port 80 on the http sites
>> or do I need to multi home the server with a unique IP for the SSL site?
>>
>>
>> Thanks
>>
>> -David.
>>
>>
>> Below is an illustration of the httpd.conf.
>>
>>
>> ServerName www.donations.org.nz
>> DocumentRoot /var/www/html/donations
>> ErrorLog /var/log/httpd/donations-error_log
>> TransferLog /var/log/httpd/donations-access_log
>>
>>
>> NameVirtualHost 219.88.240.45
>>
>>
>> ServerName stats.domain1.co.nz
>> DocumentRoot /var/www/html/domain1
>> ErrorLog /var/log/httpd/domain1-error_log
>> TransferLog /var/log/httpd/domain1-access_log
>>
>>
>>
>> ServerName stats.domain2.co.nz
>> DocumentRoot /var/www/html/domain2
>> ErrorLog /var/log/httpd/domain2-error_log
>> TransferLog /var/log/httpd/domain2-access_log
>>
>>
>>
>> ServerName stats.domain3.co.nz
>> DocumentRoot /var/www/html/domain3
>> ErrorLog /var/log/httpd/domain3-error_log
>> TransferLog /var/log/httpd/domain3-access_log
>>
>>
>>
>>
>>
>> ____________________________________________________________ __________
>> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
>> User Support Mailing List modssl-users@modssl.org
>> Automated List Manager majordomo@modssl.org
>
>
>
>
> ____________________________________________________________ __________
> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
> User Support Mailing List modssl-users@modssl.org
> Automated List Manager majordomo@modssl.org
>
____________________________________________________________ __________
Apache Interface to OpenSSL (mod_ssl) www.modssl.org
User Support Mailing List modssl-users@modssl.org
Automated List Manager majordomo@modssl.org
Re: SSL site loads regardless of URL??
am 18.06.2002 02:48:24 von david
Hi,
I tried adding port 80 to the virtual hosts as you suggested but the
issue still persists?
-David.
Peter Viertel wrote:
> Virtual hosts are defined agains the listening addresses you have for
> your host:
>
> Not sure what some of the host names resolve to but assuming 192.168
> addresses are the actual ip of your host, and the other ip is the nat
> outside address for your host then the config would look like this:
>
>
> ServerName www.donations.org.nz
> DocumentRoot /var/www/html/donations
> ErrorLog /var/log/httpd/donations-error_log
> TransferLog /var/log/httpd/donations-access_log
>
>
> NameVirtualHost 192.168.1.9:80
>
>
> ServerName stats.domain1.co.nz
> DocumentRoot /var/www/html/domain1
> ErrorLog /var/log/httpd/domain1-error_log
> TransferLog /var/log/httpd/domain1-access_log
>
>
>
> ServerName stats.domain2.co.nz
> DocumentRoot /var/www/html/domain2
> ErrorLog /var/log/httpd/domain2-error_log
> TransferLog /var/log/httpd/domain2-access_log
>
>
>
> ServerName stats.domain3.co.nz
> DocumentRoot /var/www/html/domain3
> ErrorLog /var/log/httpd/domain3-error_log
> TransferLog /var/log/httpd/domain3-access_log
>
>
>
> David wrote:
>
>> Hi,
>>
>> I have several virtually hosted web sites and only one site that is
>> configured for SSL on my server.
>>
>> The issue is if someone uses https instead of http the certificated site
>> pages load regardless of the url ie
>>
>> http://stats.domain1.co.nz loads pages from ../domain1 which is correct.
>>
>> https://stats.domain1.co.nz loads pages from ../donations, and the url
>> remains https://stats.domain1.co.nz
>>
>> I assume I have a misconfigured .conf file?
>>
>> How can I resolve this, do I need to specify port 80 on the http sites
>> or do I need to multi home the server with a unique IP for the SSL site?
>>
>>
>> Thanks
>>
>> -David.
>>
>>
>> Below is an illustration of the httpd.conf.
>>
>>
>> ServerName www.donations.org.nz
>> DocumentRoot /var/www/html/donations
>> ErrorLog /var/log/httpd/donations-error_log
>> TransferLog /var/log/httpd/donations-access_log
>>
>>
>> NameVirtualHost 219.88.240.45
>>
>>
>> ServerName stats.domain1.co.nz
>> DocumentRoot /var/www/html/domain1
>> ErrorLog /var/log/httpd/domain1-error_log
>> TransferLog /var/log/httpd/domain1-access_log
>>
>>
>>
>> ServerName stats.domain2.co.nz
>> DocumentRoot /var/www/html/domain2
>> ErrorLog /var/log/httpd/domain2-error_log
>> TransferLog /var/log/httpd/domain2-access_log
>>
>>
>>
>> ServerName stats.domain3.co.nz
>> DocumentRoot /var/www/html/domain3
>> ErrorLog /var/log/httpd/domain3-error_log
>> TransferLog /var/log/httpd/domain3-access_log
>>
>>
>>
>>
>>
>> ____________________________________________________________ __________
>> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
>> User Support Mailing List modssl-users@modssl.org
>> Automated List Manager majordomo@modssl.org
>
>
>
>
> ____________________________________________________________ __________
> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
> User Support Mailing List modssl-users@modssl.org
> Automated List Manager majordomo@modssl.org
>
____________________________________________________________ __________
Apache Interface to OpenSSL (mod_ssl) www.modssl.org
User Support Mailing List modssl-users@modssl.org
Automated List Manager majordomo@modssl.org
Re: SSL site loads regardless of URL??
am 18.06.2002 10:42:11 von Peter Viertel
I went back and read your question again, and can see I missed your
problem entirely.
You can only have one SSL certificate per IP - that is to say that
namevirtualhost does work on https, but always only one cert.. .this is
because of the number one most FAQ on this list which is what Ralf
describes as 'Some sort of chicken and egg problem' in his mod_ssl FAQ.
If you want to make it so your ssl pages only come up when the client
uses the right hostname then try this hack:
NameVirtualHost 192.168.1.9:443
ServerName oddshostnames
RewriteEngine On
RewriteRule ^ [F,L]
ServerName www.donations.org.nz
DocumentRoot /var/www/html/donations
ErrorLog /var/log/httpd/donations-error_log
TransferLog /var/log/httpd/donations-access_log
David wrote:
> Hi,
>
> I tried adding port 80 to the virtual hosts as you suggested but the
> issue still persists?
>
> -David.
>
>
> Peter Viertel wrote:
>
>> Virtual hosts are defined agains the listening addresses you have for
>> your host:
>>
>> Not sure what some of the host names resolve to but assuming 192.168
>> addresses are the actual ip of your host, and the other ip is the nat
>> outside address for your host then the config would look like this:
>>
>>
>> ServerName www.donations.org.nz
>> DocumentRoot /var/www/html/donations
>> ErrorLog /var/log/httpd/donations-error_log
>> TransferLog /var/log/httpd/donations-access_log
>>
>>
>> NameVirtualHost 192.168.1.9:80
>>
>>
>> ServerName stats.domain1.co.nz
>> DocumentRoot /var/www/html/domain1
>> ErrorLog /var/log/httpd/domain1-error_log
>> TransferLog /var/log/httpd/domain1-access_log
>>
>>
>>
>> ServerName stats.domain2.co.nz
>> DocumentRoot /var/www/html/domain2
>> ErrorLog /var/log/httpd/domain2-error_log
>> TransferLog /var/log/httpd/domain2-access_log
>>
>>
>>
>> ServerName stats.domain3.co.nz
>> DocumentRoot /var/www/html/domain3
>> ErrorLog /var/log/httpd/domain3-error_log
>> TransferLog /var/log/httpd/domain3-access_log
>>
>>
>>
>> David wrote:
>>
>>> Hi,
>>>
>>> I have several virtually hosted web sites and only one site that is
>>> configured for SSL on my server.
>>>
>>> The issue is if someone uses https instead of http the certificated
>>> site
>>> pages load regardless of the url ie
>>>
>>> http://stats.domain1.co.nz loads pages from ../domain1 which is
>>> correct.
>>>
>>> https://stats.domain1.co.nz loads pages from ../donations, and the url
>>> remains https://stats.domain1.co.nz
>>>
>>> I assume I have a misconfigured .conf file?
>>>
>>> How can I resolve this, do I need to specify port 80 on the http sites
>>> or do I need to multi home the server with a unique IP for the SSL
>>> site?
>>>
>>>
>>> Thanks
>>>
>>> -David.
>>>
>>>
>>> Below is an illustration of the httpd.conf.
>>>
>>>
>>> ServerName www.donations.org.nz
>>> DocumentRoot /var/www/html/donations
>>> ErrorLog /var/log/httpd/donations-error_log
>>> TransferLog /var/log/httpd/donations-access_log
>>>
>>>
>>> NameVirtualHost 219.88.240.45
>>>
>>>
>>> ServerName stats.domain1.co.nz
>>> DocumentRoot /var/www/html/domain1
>>> ErrorLog /var/log/httpd/domain1-error_log
>>> TransferLog /var/log/httpd/domain1-access_log
>>>
>>>
>>>
>>> ServerName stats.domain2.co.nz
>>> DocumentRoot /var/www/html/domain2
>>> ErrorLog /var/log/httpd/domain2-error_log
>>> TransferLog /var/log/httpd/domain2-access_log
>>>
>>>
>>>
>>> ServerName stats.domain3.co.nz
>>> DocumentRoot /var/www/html/domain3
>>> ErrorLog /var/log/httpd/domain3-error_log
>>> TransferLog /var/log/httpd/domain3-access_log
>>>
>>>
>>>
>>>
>>>
>>> ____________________________________________________________ __________
>>> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
>>> User Support Mailing List modssl-users@modssl.org
>>> Automated List Manager majordomo@modssl.org
>>
>>
>>
>>
>>
>> ____________________________________________________________ __________
>> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
>> User Support Mailing List modssl-users@modssl.org
>> Automated List Manager majordomo@modssl.org
>>
>
>
>
> ____________________________________________________________ __________
> Apache Interface to OpenSSL (mod_ssl) www.modssl.org
> User Support Mailing List modssl-users@modssl.org
> Automated List Manager majordomo@modssl.org
____________________________________________________________ __________
Apache Interface to OpenSSL (mod_ssl) www.modssl.org
User Support Mailing List modssl-users@modssl.org
Automated List Manager majordomo@modssl.org