Merge "Implement secure RBAC for floating IP pools API"
This commit is contained in:
commit
51e0572315
|
@ -10,22 +10,31 @@
|
||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
|
from oslo_log import versionutils
|
||||||
from oslo_policy import policy
|
from oslo_policy import policy
|
||||||
|
|
||||||
from neutron.conf.policies import base
|
from neutron.conf.policies import base
|
||||||
|
|
||||||
|
DEPRECATED_REASON = (
|
||||||
|
"The Floating IP Pool API now supports system scope and default roles.")
|
||||||
|
|
||||||
rules = [
|
rules = [
|
||||||
policy.DocumentedRuleDefault(
|
policy.DocumentedRuleDefault(
|
||||||
'get_floatingip_pool',
|
name='get_floatingip_pool',
|
||||||
base.RULE_ANY,
|
check_str=base.SYSTEM_OR_PROJECT_READER,
|
||||||
'Get floating IP pools',
|
description='Get floating IP pools',
|
||||||
[
|
operations=[
|
||||||
{
|
{
|
||||||
'method': 'GET',
|
'method': 'GET',
|
||||||
'path': '/floatingip_pools',
|
'path': '/floatingip_pools',
|
||||||
},
|
},
|
||||||
]
|
],
|
||||||
|
scope_types=['admin', 'project'],
|
||||||
|
deprecated_rule=policy.DeprecatedRule(
|
||||||
|
name='get_floatingip_pool',
|
||||||
|
check_str=base.RULE_ANY),
|
||||||
|
deprecated_reason=DEPRECATED_REASON,
|
||||||
|
deprecated_since=versionutils.deprecated.WALLABY
|
||||||
),
|
),
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue