Redirect loop

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Redirect loop

Pooya Eslami
This post has NOT been accepted by the mailing list yet.
Hi everyone...

I have a plone site that serves on http://my.domain.com:8080/intranet.
Based on the plone docs I have a rewrite rule so to translate that ugliness to http://my.domain.com
I have cas enabled on the plone site for authentication and it works fine.
Several pages at the root level are available to public unfortunately. So to protect these pages via cas, I have installed the mod_auth_cas in apache.
Now the pages that were previously public are protected by cas, but if I try to go to the root site http://my.domain.com/ I get a redirect loop that keeps generating tickets and goes between cas and my.domain.com trying to validate.

here is my apache conf:


<VirtualHost *>
    ServerName my.domain.com
    ServerSignature On

    ProxyVia On

    <Proxy *>
        Order deny,allow
        Allow from all
    </Proxy>

    CASCookiePath    /var/cache/apache2/mod_auth_cas/
    CASLoginURL      https://cas.domain.com/cas/login
    CASValidateURL   https://cas.domain.com/cas/serviceValidate
    CASDebug         on
    LogLevel         Debug

    RewriteEngine on
    RewriteRule ^/(.*) <a href="http://localhost:8080/VirtualHostBase/http/%">http://localhost:8080/VirtualHostBase/http/%{SERVER_NAME}:80/intranet/VirtualHostRoot/$1 [P,L]

    <Location />
        CASScope on
        AuthType CAS
        require valid-user
    </Location>

</VirtualHost>


Any advice will be appreciated. Thanks