[Zope] A login page

J Cameron Cooper jccooper at jcameroncooper.com
Thu Aug 28 19:16:35 EDT 2003


>I'm a newbie in this excellent package and I need some help. I'm trying to
>do a simple login page (username and password text fields and a button)
>that enable or disable the navigation into a Zope project. This mean that
>if you didn't login you can't be able to surf the project. This sound easy
>to do but I can't do it :-(
>
You have two things to do: form-based login and restricting your site to 
authenticated users. Fortunately, both are pretty easy.

Form-based login requires something other than the default Zope methods. 
CookieCutter, as previously suggested, is a good choice.

Allowing view access only to authenticated users means a quick trip to 
the "Security" tab at the most basic level you want to secure: the 
children of that object will inherit these settings unless told 
otherwise. Just remove the "Anonymous" role from the permission that 
allows viewing of content. This is, unless elsewhere changed, "View". Do 
this and you have to be logged in to see the content (presuming some 
other role has the permission). You may even want to further restrict 
the Anonymous role.

             --jcc




More information about the Zope mailing list