[Zope-CMF] using zope authentication outside of Zope...

larry_prikockis@natureserve.org larry_prikockis@natureserve.org
Mon, 20 May 2002 15:07:19 -0400


Shane,
   PHP has no problem dealing with cookies... it's simple enough even for me
:-)   The problem seems to be that the cookie set by Zope doesn't get served
up to the browser when I'm in the php application.  I'm assuming this has to
do with the way the cookie 'domain' and 'path' are set by Zope/CMF, but I'm
not quite sure how to go about tinkering with that without messing up my
Zope authentication.

I probably should've mentioned that I'm running Zope behind Apache (1.3.22 -
I'm aware of the cookie problems with .23+).  So.... http://mysite/forum/
gets served up directly by apache; anything else gets proxied to
http://mysite:8080/cmf_site

I'm sure it's all this rewriting/proxying stuff that's causing my cookie
woes, but I don't understand enough about cookies and how Zope uses them to
sort it out.

> -----Original Message-----
> From: Shane Hathaway [mailto:shane@zope.com]
> Sent: Monday, May 20, 2002 2:55 PM
> To: larry_prikockis@natureserve.org
> Cc: zope-cmf@zope.org
> Subject: Re: [Zope-CMF] using zope authentication outside of Zope...
> 
> 
> larry_prikockis@natureserve.org wrote:
> > I'd like to use a php-based forum (w-agora) as part of a 
> site that will be
> > otherwise built in Zope/CMF.
> > Is there a relatively simple way of getting at the __AC 
> cookie zope is using
> > for authentication from this php application?  
> > 
> You just need to get PHP to decode the __ac cookie, I think.  
> Its value 
> consists of the username and password, joined with a colon, 
> then base 64 
> encoded.  PHP probably provides a way almost as easy as 
> Python to decode 
> that.  Then perhaps it could authenticate against an LDAP 
> database that 
> both Zope and PHP use.