Security Policy in Launchpad¶
Zope 3 is a security-aware framework that makes it possible to develop complex applications with security policies that closely resemble the reality that the system is trying to model.
This document is about security policy in Launchpad.
Defining Permissions in Launchpad¶
NOTE: A new permission should only be defined if absolutely necessary, and it should be considered thoroughly in a code review.
Occassionally, you’ll find yourself in a situation where the existing permissions in Launchpad aren’t enough for what you want. For example, as I was writing this document I needed a permission I could attach to things to provide policy for who can view a thing. That is, I wanted a permission called launchpad.View. A new permission (see the NOTE above) is defined in Launchpad in the file lib/canonical/launchpad/permissions.zcml. So, to define the permission launchpad.View, we’d add a line like this to that file:
- <permission id=”launchpad.View” title=”Viewing something”
- access_level=”read” />