[Zope] Programmatically logging out a user

Andrew Milton akm at theinternet.com.au
Tue Oct 3 08:33:33 EDT 2006

+-------[ Sinang, Danny ]----------------------
| Hello,
| How do I programmatically log out a user from Zope ?
| I've asked this question before, but was told to :
| 1. Redirect the user to a page that always raises Unauthenticated. See
| manage_zmi_logout.
| 2. from AccessControl.SecurityManagement import noSecurityManager
| noSecurityManager()
| Are there any other ways out there ?

That depends on the type of 'authentication' you're using.

If you're using Cookie based auth, the convention for zope user folders (and
CookieCrumbler) is to use the __ac cookie, so you can also try deleting that.

Andrew Milton
akm at theinternet.com.au

More information about the Zope mailing list