[Zope] Apache ProxyPass to Zope

Russell Seymour russell.seymour at turtlesystems.co.uk
Fri Oct 29 06:16:41 EDT 2004


Thanks for the suggestions Cliff, the thing is that I need Apache to 
take care of the authentication.

This is because I am setting up a Zope application within an existing 
Virtual Host which already has the authentication setup on it.  This is 
done using a Perl script which communicates with a Windows 2003 AD.  I 
want to keep it this way so that it is easy to understand where the 
authntication is taking place and is only in one place.

Is it not possible to do what I want to do at all?

Thanks,  Russell

Cliff Ford wrote:

> I guess I would put it a bit stronger than Tino: don't waste your time 
> trying to authenticate with Apache. Just past the request through 
> Apache to Zope and do the authentication there. In my site, one of the 
> things that Apache does is switch to secure mode (https) for login. It 
> is Zope that needs to authenticate by changing its AUTHENTICATED_USER 
> from Anonymous to something else.
>
> Cliff
>
> Russell Seymour wrote:
>
>> Good evening list,
>>
>> I have been trying to get the REMOTE_USER variable to be seen by 
>> Zope.  I have almost got there by using various articles on the 
>> Internet, but I need a little bit of help to get the last bit working.
>>
>> I have got Apache performing the authentication and this works well 
>> as I get the Zope page when I enter a valid username and password.  I 
>> have noticed that the Z2 log file for my Zope instances contains the 
>> username that I have used to access the site, but I cannot get Zope 
>> itself to see the username - this is the most confusing bit for me as 
>> it surely means that the username is being passed to Zope.
>>
>> The following is a snippet from my Apache:
>>
>> <Location /zope>
>>    AuthName "Zope Access"
>>    AuthType Basic
>>
>>    <AUTHENTICATION ROUTINES>
>>    require valid-user
>>
>>    ProxyPass http://x.x.x.x:8080/zope
>>
>> </Location>
>>
>> ProxyPassReverse /zope http://x.x.x.x:8080/zope
>>
>> This all works brilliantly apart from the fact that I cannot get the 
>> username in Zope.  I need this do I can do some custom authorisation 
>> to a database that my Zope application accesses.
>>
>> I have tried many different variations using RewriteRule and trying 
>> to set the environment variables but to no avail.
>>
>> Thanks to anyone that can give me some pointers.
>>
>> Russell
>> _______________________________________________
>> Zope maillist  -  Zope at zope.org
>> http://mail.zope.org/mailman/listinfo/zope
>> **   No cross posts or HTML encoding!  **
>> (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce
>> http://mail.zope.org/mailman/listinfo/zope-dev )
>


More information about the Zope mailing list