Re: Default HTTPS VH to redirect to a HTTP page

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

 



On Mon, Mar 29, 2010 at 1:13 PM, Sandro Tosi <sandro.tosi@xxxxxxxxxxx> wrote:
> Hello,
> we're setting up an Apache to respond for SSL traffic. We have a set of VHs,
> each one for a different domain (we use SNI), and that part works fine.
>
> The additional requirement is that, for every domain that doesn't have a
> separate VH (so that goes into the default SSL VH) we want to redirect to a
> simple HTML page.
>
> We do not want to associate any certificate into the default SSL VH because
> it will serve several domains and there won't be any cert matching all of
> them; so we were thinking about redirect every request done in the default
> VH to a static HTML page served in plain HTTP (by the same Apache, but on
> the port 80).
>
> The problem is that the "simple" configuration (for default SSL VH):
>
> <VirtualHost _default_:443>
>
> ProxyPass / http://localhost:80/
> ProxyPassReverse / http://localhost:80/
>
> </VirtualHost>
>
> doesn't work, returning a "Invalid method in request \x16\x03\x01 /
> HTTP/1.1" because it's trying to "talk SSL" with a non-SSL VH. We also tried
> a rewriterule with still with no success.
>
> So, to make it short :) how can I redirect all the traffic we receive on the
> default SSL VH to a non-SSL VH (because we don't want to have any
> certificate, we think of a plain HTTP VH) or to a single (static HTML) web
> page?
>
> Thanks in advance,
> Sandro
>

You can't. You can configure your 'default' vhost with one of your
certificates, in which case it will work for some domains, and give
certificate errors for others. This is a limitation of SSL, not
apache.

Cheers

Tom

---------------------------------------------------------------------
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: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[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