1

I'm new on Plone and I'm developing a small add-on package.

How can I define a permission so that only logged users can access to the pages of the package?

The actual permission is the following:

<browser:page
 name="homepage"
 for="*"
 permissions="zope.View"
 class=".homepage.HomepageView"
 />

With the standard permissions="zope.View" the page is accessible from everyone.

Massimo Variolo
  • 4,669
  • 6
  • 38
  • 64

1 Answers1

3

You can either create your own permission or use an existing permission that is only granted to registered users by default, e.g. the "cmf.SetOwnPassword" permission:

<browser:page
  name="homepage"
  for="*"
  permission="cmf.SetOwnPassword"
  class=".homepage.HomepageView"
/>
tisto
  • 1,337
  • 7
  • 13
  • 1
    Of course, for any re-used permission, somebody comes along and finds a counterexample – I'm not sure if members still have, or should have, `Set own password` if they authenticate against LDAP, AD, Shibboleth, or whatever. I'd be tempted to go with `Portlets: View dashboard`, and now you're welcome to point out a counterexample for that ;) – Ulrich Schwarz Jan 13 '15 at 14:04