
RoleCheck.__call__() doesn't render string format with target dict. So, it couldn't handle rules like below: "identity:create_grant": "role: %{target.role.name}s" This patch adds string format rendering code to it. If target_dict has a key specified at %()s in the rule, __call__() will render its value and evaluate the rule. If not, the method will return False. Change-Id: I82d677301ca2c764230ed9b3e3e9d82056afcea2 Closes-Bug: #1527055
oslo.policy
The Oslo Policy library provides support for RBAC policy enforcement across all OpenStack services.
- Free software: Apache license
- Documentation: http://docs.openstack.org/developer/oslo.policy
- Source: http://git.openstack.org/cgit/openstack/oslo.policy
- Bugs: http://bugs.launchpad.net/oslo.policy
Description
Languages
Python
100%