I've done this by not using the Zend_Auth singleton at all. Instead I just use the adapter on its own for authentication and then save the resulting identity object(s) into my own session namespace(s). When I need to check if someone is logged in I just check if the session variable is set. Perhaps there is a way to do it using the Zend_Auth singleton, but I couldn't figure it out, and this is simple enough for me.

debussy007 wrote:
Hello !

I wondered how it was possible for one user to authenticate more than once :

E.g. my web application is composed of several modules.
default / partners / admin.

And a "partner" can connect as a "member" (default module) at the same time,
as well as an "admin".

I tought of changing the namespace from Zend_Auth to Zend_Member_Auth, Zend_Partner_Auth, Zend_Admin_Auth.

But now I am confused : - how can I check for valid identity ccording to the module ? (a member connected in the default module cannot access partner nor admin module without valid authentication) - how can I clear the identity of a specific auth namespace ? (if a user logs outs from member module, he must not logs out from
partner module automatically)

I tought of a solution for this : each time the request goes into the bootstrap, I check the module which is
called,
and call ...->setStorage(new Zend_Auth_Storage_Session('Zend_XYZ_Auth')); according to the module called (XYZ can be Member, Partner or Admin
according to the module called).

But now I don't really know how to do this.

Maybe I am also totally wrong about the use of the namespace!

Thank you for any help.

--
Jack

Reply via email to