Common Policy Engine Implementation
Bases: object
Implements policy checking.
Checks authorization of some rules against credentials.
Detailed description of the check with examples in policy.enforce().
| Parameters: |
|
|---|---|
| Returns: | True if the check passes |
Init a brain using json instead of a rules dictionary.
Bases: cinder.openstack.common.policy.Brain
A brain that can check external urls for policy.
Posts json blobs for target and credentials.
Note that this brain is deprecated; the http check is registered by default.
Enforces authorization of some rules against credentials.
| Parameters: |
|
|---|---|
| Returns: | True if the policy allows the action |
| Returns: | False if the policy does not allow the action and exc is not set |
Register a function as a policy check.
| Parameters: |
|
|---|
Clear the brain used by enforce().
Set the brain used by enforce().
Defaults use Brain() if not set.