forcing http to go to https

Alexander Dalloz alexander.dalloz at uni-bielefeld.de
Thu Jun 24 23:35:44 UTC 2004


Am Fr, den 25.06.2004 schrieb Steven Stern um 1:02:

> >Put these lines in the /etc/httpd/conf/httpd.conf anywhere near the end.
> >Don't put it inside the SSL vhost config!
> 
> Bear with me a little more.  I'm still not seeing how the loop is created. 
> 
> I need to have the rewrite to avoid http://webroot.mydomain.com/horde being
> available.  
> 
> The <directory> re-write is at the very end of httpd.conf, after all virtual
> servers have been defined.  I still get the too many redirects error.
> 
> Here's an abstracted version of httpd.conf.  When I uncomment that last
> <directory> stanza, things go bad.
> 
> Listen 80

Having the SSL vhost inside the main httpd.conf I miss "Listen 443".

> DocumentRoot "/var/www/html"
> <Directory "/var/www/html">

[ snipped named vhosts ]

> <VirtualHost *:443>
>    ServerAdmin  webmaster at foo.com
>    DocumentRoot /var/www/html/horde/
>    Alias /horde/ /var/www/html/horde/
>    ServerName webmail.foo.com
>  </VirtualHost>
> 
> #<Directory /var/www/html/horde/>
> #    RewriteEngine      on
> #    RewriteCond        %{SERVER_PORT} !=443
> #    RewriteRule         ^.* - [F]
> #    ErrorDocument    403 https://webmail.foo.com/
> #</Directory>

Why below the Virtual Hosts section? I am not sure how that matters, but
just from logic I would place what's for the main server before calling
any vhost. Else I don't see errors from what you posted. Isn't the
error_log helpful? Did you restart the server?

>    Steve

Alexander


-- 
Alexander Dalloz | Enger, Germany | GPG key 1024D/ED695653 1999-07-13
Fedora GNU/Linux Core 2 (Tettnang) on Athlon CPU kernel 2.6.6-1.435 
Serendipity 01:31:41 up 2 days, 9 users, load average: 1.55, 1.27, 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Dies ist ein digital signierter Nachrichtenteil
URL: <http://listman.redhat.com/archives/fedora-list/attachments/20040625/cc87ccf5/attachment-0001.sig>


More information about the fedora-list mailing list