Flask extension for registration and checking of ACLs on routes and other objects.
Make sure we have a permission, or abort the request.
| Parameters: |
|
|---|
Check if we can do something with an object.
| Parameters: |
|
|---|
>>> auth.can('read', some_object)
>>> auth.can('write', another_object, group=some_group)
Make sure we can route to the given endpoint or url.
This checks for http.get permission (or other methods) on the ACL of route functions, attached via the ACL decorator.
| Parameters: |
|
|---|
Register a function to build authorization contexts.
The function is called with no arguments, and must return a dict of new context material.
Define a new permission set (directly, or as a decorator).