Mykola Yakovliev | 11376ab | 2018-08-06 15:34:22 -0500 | [diff] [blame] | 1 | --- |
| 2 | features: |
| 3 | - | |
| 4 | Add new exception called ``RbacOverrideRoleException``. Used for |
| 5 | safeguarding against false positives that might occur when the expected |
| 6 | exception isn't raised inside the ``override_role`` context. Specifically, |
| 7 | when: |
| 8 | |
| 9 | * ``override_role`` isn't called |
| 10 | * an exception is raised before ``override_role`` context |
| 11 | * an exception is raised after ``override_role`` context |
| 12 | fixes: |
| 13 | - | |
| 14 | Previously, the ``rbac_rule_validation.action`` decorator could catch |
| 15 | expected exceptions with no regard to where the error happened. Such |
| 16 | behavior could cause false-positive results. To prevent this from |
| 17 | happening from now on, if an exception happens outside of the |
| 18 | ``override_role`` context, it will cause |
| 19 | ``rbac_exceptions.RbacOverrideRoleException`` to be raised. |