Fix avoid deprecation warnings from policy

We received huge amount of warnings during service start.
Most about stop using `deprecated_reason` and `deprecated_since` by
`policy.DocumentedRuleDefault` directly. And should use them under
`policy.DeprecatedRule instead.

This patch apply for above suggestion.
Also bump oslo.policy lower-constraints and requirements to `3.7.0` to alias
policy behavior.

Story: 2008707
Task: 42041

Change-Id: Iefcfc30a051fe25ccc5121c7ddb817e8c271fcb6
This commit is contained in:
Rico Lin 2021-03-12 12:35:37 +08:00
parent 66c321ffaf
commit 7230082f87
11 changed files with 275 additions and 275 deletions

View File

@ -23,31 +23,45 @@ The actions API now supports system scope and default roles.
deprecated_action = policy.DeprecatedRule( deprecated_action = policy.DeprecatedRule(
name=POLICY_ROOT % 'action', name=POLICY_ROOT % 'action',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_snapshot = policy.DeprecatedRule( deprecated_snapshot = policy.DeprecatedRule(
name=POLICY_ROOT % 'snapshot', name=POLICY_ROOT % 'snapshot',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_suspend = policy.DeprecatedRule( deprecated_suspend = policy.DeprecatedRule(
name=POLICY_ROOT % 'suspend', name=POLICY_ROOT % 'suspend',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_resume = policy.DeprecatedRule( deprecated_resume = policy.DeprecatedRule(
name=POLICY_ROOT % 'resume', name=POLICY_ROOT % 'resume',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_check = policy.DeprecatedRule( deprecated_check = policy.DeprecatedRule(
name=POLICY_ROOT % 'check', name=POLICY_ROOT % 'check',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_cancel_update = policy.DeprecatedRule( deprecated_cancel_update = policy.DeprecatedRule(
name=POLICY_ROOT % 'cancel_update', name=POLICY_ROOT % 'cancel_update',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_cancel_without_rollback = policy.DeprecatedRule( deprecated_cancel_without_rollback = policy.DeprecatedRule(
name=POLICY_ROOT % 'cancel_without_rollback', name=POLICY_ROOT % 'cancel_without_rollback',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
@ -63,9 +77,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_action, deprecated_rule=deprecated_action
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'snapshot', name=POLICY_ROOT % 'snapshot',
@ -76,9 +88,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_snapshot, deprecated_rule=deprecated_snapshot
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'suspend', name=POLICY_ROOT % 'suspend',
@ -89,9 +99,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_suspend, deprecated_rule=deprecated_suspend
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'resume', name=POLICY_ROOT % 'resume',
@ -102,9 +110,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_resume, deprecated_rule=deprecated_resume
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'check', name=POLICY_ROOT % 'check',
@ -115,9 +121,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_check, deprecated_rule=deprecated_check
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'cancel_update', name=POLICY_ROOT % 'cancel_update',
@ -128,9 +132,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_cancel_update, deprecated_rule=deprecated_cancel_update
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'cancel_without_rollback', name=POLICY_ROOT % 'cancel_without_rollback',
@ -141,9 +143,7 @@ actions_policies = [
'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions', 'path': '/v1/{tenant_id}/stacks/{stack_name}/{stack_id}/actions',
'method': 'POST', 'method': 'POST',
}], }],
deprecated_rule=deprecated_cancel_without_rollback, deprecated_rule=deprecated_cancel_without_rollback
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -23,7 +23,9 @@ POLICY_ROOT = 'build_info:%s'
deprecated_build_info = policy.DeprecatedRule( deprecated_build_info = policy.DeprecatedRule(
name=POLICY_ROOT % 'build_info', name=POLICY_ROOT % 'build_info',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
@ -39,9 +41,7 @@ build_info_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_build_info, deprecated_rule=deprecated_build_info
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -26,55 +26,81 @@ POLICY_ROOT = 'cloudformation:%s'
deprecated_list_stacks = policy.DeprecatedRule( deprecated_list_stacks = policy.DeprecatedRule(
name=POLICY_ROOT % 'ListStacks', name=POLICY_ROOT % 'ListStacks',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_create_stack = policy.DeprecatedRule( deprecated_create_stack = policy.DeprecatedRule(
name=POLICY_ROOT % 'CreateStack', name=POLICY_ROOT % 'CreateStack',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_describe_stacks = policy.DeprecatedRule( deprecated_describe_stacks = policy.DeprecatedRule(
name=POLICY_ROOT % 'DescribeStacks', name=POLICY_ROOT % 'DescribeStacks',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_delete_stack = policy.DeprecatedRule( deprecated_delete_stack = policy.DeprecatedRule(
name=POLICY_ROOT % 'DeleteStack', name=POLICY_ROOT % 'DeleteStack',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_update_stack = policy.DeprecatedRule( deprecated_update_stack = policy.DeprecatedRule(
name=POLICY_ROOT % 'UpdateStack', name=POLICY_ROOT % 'UpdateStack',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_cancel_update_stack = policy.DeprecatedRule( deprecated_cancel_update_stack = policy.DeprecatedRule(
name=POLICY_ROOT % 'CancelUpdateStack', name=POLICY_ROOT % 'CancelUpdateStack',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_describe_stack_events = policy.DeprecatedRule( deprecated_describe_stack_events = policy.DeprecatedRule(
name=POLICY_ROOT % 'DescribeStackEvents', name=POLICY_ROOT % 'DescribeStackEvents',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_validate_template = policy.DeprecatedRule( deprecated_validate_template = policy.DeprecatedRule(
name=POLICY_ROOT % 'ValidateTemplate', name=POLICY_ROOT % 'ValidateTemplate',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_get_template = policy.DeprecatedRule( deprecated_get_template = policy.DeprecatedRule(
name=POLICY_ROOT % 'GetTemplate', name=POLICY_ROOT % 'GetTemplate',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_estimate_template_cost = policy.DeprecatedRule( deprecated_estimate_template_cost = policy.DeprecatedRule(
name=POLICY_ROOT % 'EstimateTemplateCost', name=POLICY_ROOT % 'EstimateTemplateCost',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_describe_stack_resource = policy.DeprecatedRule( deprecated_describe_stack_resource = policy.DeprecatedRule(
name=POLICY_ROOT % 'DescribeStackResource', name=POLICY_ROOT % 'DescribeStackResource',
check_str=base.RULE_ALLOW_EVERYBODY check_str=base.RULE_ALLOW_EVERYBODY,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_describe_stack_resources = policy.DeprecatedRule( deprecated_describe_stack_resources = policy.DeprecatedRule(
name=POLICY_ROOT % 'DescribeStackResources', name=POLICY_ROOT % 'DescribeStackResources',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_list_stack_resources = policy.DeprecatedRule( deprecated_list_stack_resources = policy.DeprecatedRule(
name=POLICY_ROOT % 'ListStackResources', name=POLICY_ROOT % 'ListStackResources',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
cloudformation_policies = [ cloudformation_policies = [
@ -82,105 +108,79 @@ cloudformation_policies = [
name=POLICY_ROOT % 'ListStacks', name=POLICY_ROOT % 'ListStacks',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_list_stacks, deprecated_rule=deprecated_list_stacks
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'CreateStack', name=POLICY_ROOT % 'CreateStack',
check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER, check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_create_stack, deprecated_rule=deprecated_create_stack
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'DescribeStacks', name=POLICY_ROOT % 'DescribeStacks',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_describe_stacks, deprecated_rule=deprecated_describe_stacks
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'DeleteStack', name=POLICY_ROOT % 'DeleteStack',
check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER, check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_delete_stack, deprecated_rule=deprecated_delete_stack
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'UpdateStack', name=POLICY_ROOT % 'UpdateStack',
check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER, check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_update_stack, deprecated_rule=deprecated_update_stack
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'CancelUpdateStack', name=POLICY_ROOT % 'CancelUpdateStack',
check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER, check_str=base.SYSTEM_ADMIN_OR_PROJECT_MEMBER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_cancel_update_stack, deprecated_rule=deprecated_cancel_update_stack
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'DescribeStackEvents', name=POLICY_ROOT % 'DescribeStackEvents',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_describe_stack_events, deprecated_rule=deprecated_describe_stack_events
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'ValidateTemplate', name=POLICY_ROOT % 'ValidateTemplate',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_validate_template, deprecated_rule=deprecated_validate_template
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'GetTemplate', name=POLICY_ROOT % 'GetTemplate',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_get_template, deprecated_rule=deprecated_get_template
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'EstimateTemplateCost', name=POLICY_ROOT % 'EstimateTemplateCost',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_estimate_template_cost, deprecated_rule=deprecated_estimate_template_cost
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'DescribeStackResource', name=POLICY_ROOT % 'DescribeStackResource',
check_str=base.SYSTEM_OR_PROJECT_READER_OR_STACK_USER, check_str=base.SYSTEM_OR_PROJECT_READER_OR_STACK_USER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_describe_stack_resource, deprecated_rule=deprecated_describe_stack_resource
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'DescribeStackResources', name=POLICY_ROOT % 'DescribeStackResources',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_describe_stack_resources, deprecated_rule=deprecated_describe_stack_resources
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'ListStackResources', name=POLICY_ROOT % 'ListStackResources',
check_str=base.SYSTEM_OR_PROJECT_READER, check_str=base.SYSTEM_OR_PROJECT_READER,
scope_types=['system', 'project'], scope_types=['system', 'project'],
deprecated_rule=deprecated_list_stack_resources, deprecated_rule=deprecated_list_stack_resources
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -23,11 +23,15 @@ The events API now supports system scope and default roles.
deprecated_index = policy.DeprecatedRule( deprecated_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show = policy.DeprecatedRule( deprecated_show = policy.DeprecatedRule(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
@ -44,9 +48,7 @@ events_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_index, deprecated_rule=deprecated_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
@ -60,9 +62,7 @@ events_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show, deprecated_rule=deprecated_show
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -23,23 +23,33 @@ The resources API now supports system scope and default roles.
deprecated_list_resources = policy.DeprecatedRule( deprecated_list_resources = policy.DeprecatedRule(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_mark_unhealthy = policy.DeprecatedRule( deprecated_mark_unhealthy = policy.DeprecatedRule(
name=POLICY_ROOT % 'mark_unhealthy', name=POLICY_ROOT % 'mark_unhealthy',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show_resource = policy.DeprecatedRule( deprecated_show_resource = policy.DeprecatedRule(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
check_str=base.RULE_DENY_STACK_USER, check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY,
) )
deprecated_metadata = policy.DeprecatedRule( deprecated_metadata = policy.DeprecatedRule(
name=POLICY_ROOT % 'metadata', name=POLICY_ROOT % 'metadata',
check_str=base.RULE_ALLOW_EVERYBODY, check_str=base.RULE_ALLOW_EVERYBODY,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY,
) )
deprecated_signal = policy.DeprecatedRule( deprecated_signal = policy.DeprecatedRule(
name=POLICY_ROOT % 'signal', name=POLICY_ROOT % 'signal',
check_str=base.RULE_ALLOW_EVERYBODY, check_str=base.RULE_ALLOW_EVERYBODY,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY,
) )
resource_policies = [ resource_policies = [
@ -55,9 +65,7 @@ resource_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_list_resources, deprecated_rule=deprecated_list_resources
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'metadata', name=POLICY_ROOT % 'metadata',
@ -71,9 +79,7 @@ resource_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_metadata, deprecated_rule=deprecated_metadata
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'signal', name=POLICY_ROOT % 'signal',
@ -87,9 +93,7 @@ resource_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_signal, deprecated_rule=deprecated_signal
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'mark_unhealthy', name=POLICY_ROOT % 'mark_unhealthy',
@ -103,9 +107,7 @@ resource_policies = [
'method': 'PATCH' 'method': 'PATCH'
} }
], ],
deprecated_rule=deprecated_mark_unhealthy, deprecated_rule=deprecated_mark_unhealthy
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
@ -119,9 +121,7 @@ resource_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show_resource, deprecated_rule=deprecated_show_resource
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -23,16 +23,16 @@ POLICY_ROOT = 'service:%s'
deprecated_index = policy.DeprecatedRule( deprecated_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.RULE_CONTEXT_IS_ADMIN check_str=base.RULE_CONTEXT_IS_ADMIN,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
service_policies = [ service_policies = [
policy.RuleDefault( policy.RuleDefault(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.SYSTEM_READER, check_str=base.SYSTEM_READER,
deprecated_rule=deprecated_index, deprecated_rule=deprecated_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -23,23 +23,33 @@ POLICY_ROOT = 'software_configs:%s'
deprecated_global_index = policy.DeprecatedRule( deprecated_global_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'global_index', name=POLICY_ROOT % 'global_index',
check_str=base.RULE_DENY_EVERYBODY check_str=base.RULE_DENY_EVERYBODY,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_index = policy.DeprecatedRule( deprecated_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_create = policy.DeprecatedRule( deprecated_create = policy.DeprecatedRule(
name=POLICY_ROOT % 'create', name=POLICY_ROOT % 'create',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show = policy.DeprecatedRule( deprecated_show = policy.DeprecatedRule(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_delete = policy.DeprecatedRule( deprecated_delete = policy.DeprecatedRule(
name=POLICY_ROOT % 'delete', name=POLICY_ROOT % 'delete',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
software_configs_policies = [ software_configs_policies = [
@ -54,9 +64,7 @@ software_configs_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_global_index, deprecated_rule=deprecated_global_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
@ -69,9 +77,7 @@ software_configs_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_index, deprecated_rule=deprecated_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'create', name=POLICY_ROOT % 'create',
@ -84,9 +90,7 @@ software_configs_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_create, deprecated_rule=deprecated_create
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
@ -99,9 +103,7 @@ software_configs_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show, deprecated_rule=deprecated_show
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'delete', name=POLICY_ROOT % 'delete',
@ -114,9 +116,7 @@ software_configs_policies = [
'method': 'DELETE' 'method': 'DELETE'
} }
], ],
deprecated_rule=deprecated_delete, deprecated_rule=deprecated_delete
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -23,23 +23,33 @@ POLICY_ROOT = 'software_deployments:%s'
deprecated_index = policy.DeprecatedRule( deprecated_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_create = policy.DeprecatedRule( deprecated_create = policy.DeprecatedRule(
name=POLICY_ROOT % 'create', name=POLICY_ROOT % 'create',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show = policy.DeprecatedRule( deprecated_show = policy.DeprecatedRule(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_update = policy.DeprecatedRule( deprecated_update = policy.DeprecatedRule(
name=POLICY_ROOT % 'update', name=POLICY_ROOT % 'update',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_delete = policy.DeprecatedRule( deprecated_delete = policy.DeprecatedRule(
name=POLICY_ROOT % 'delete', name=POLICY_ROOT % 'delete',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
@ -55,9 +65,7 @@ software_deployments_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_index, deprecated_rule=deprecated_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'create', name=POLICY_ROOT % 'create',
@ -70,9 +78,7 @@ software_deployments_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_create, deprecated_rule=deprecated_create
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
@ -85,9 +91,7 @@ software_deployments_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show, deprecated_rule=deprecated_show
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'update', name=POLICY_ROOT % 'update',
@ -100,9 +104,7 @@ software_deployments_policies = [
'method': 'PUT' 'method': 'PUT'
} }
], ],
deprecated_rule=deprecated_update, deprecated_rule=deprecated_update
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'delete', name=POLICY_ROOT % 'delete',
@ -115,9 +117,7 @@ software_deployments_policies = [
'method': 'DELETE' 'method': 'DELETE'
} }
], ],
deprecated_rule=deprecated_delete, deprecated_rule=deprecated_delete
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'metadata', name=POLICY_ROOT % 'metadata',

View File

@ -23,123 +23,183 @@ POLICY_ROOT = 'stacks:%s'
deprecated_abandon = policy.DeprecatedRule( deprecated_abandon = policy.DeprecatedRule(
name=POLICY_ROOT % 'abandon', name=POLICY_ROOT % 'abandon',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_create = policy.DeprecatedRule( deprecated_create = policy.DeprecatedRule(
name=POLICY_ROOT % 'create', name=POLICY_ROOT % 'create',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_delete = policy.DeprecatedRule( deprecated_delete = policy.DeprecatedRule(
name=POLICY_ROOT % 'delete', name=POLICY_ROOT % 'delete',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_detail = policy.DeprecatedRule( deprecated_detail = policy.DeprecatedRule(
name=POLICY_ROOT % 'detail', name=POLICY_ROOT % 'detail',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_export = policy.DeprecatedRule( deprecated_export = policy.DeprecatedRule(
name=POLICY_ROOT % 'export', name=POLICY_ROOT % 'export',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_generate_template = policy.DeprecatedRule( deprecated_generate_template = policy.DeprecatedRule(
name=POLICY_ROOT % 'generate_template', name=POLICY_ROOT % 'generate_template',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_global_index = policy.DeprecatedRule( deprecated_global_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'global_index', name=POLICY_ROOT % 'global_index',
check_str=base.RULE_DENY_EVERYBODY check_str=base.RULE_DENY_EVERYBODY,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_index = policy.DeprecatedRule( deprecated_index = policy.DeprecatedRule(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_list_resource_types = policy.DeprecatedRule( deprecated_list_resource_types = policy.DeprecatedRule(
name=POLICY_ROOT % 'list_resource_types', name=POLICY_ROOT % 'list_resource_types',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_list_template_versions = policy.DeprecatedRule( deprecated_list_template_versions = policy.DeprecatedRule(
name=POLICY_ROOT % 'list_template_versions', name=POLICY_ROOT % 'list_template_versions',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_list_template_functions = policy.DeprecatedRule( deprecated_list_template_functions = policy.DeprecatedRule(
name=POLICY_ROOT % 'list_template_functions', name=POLICY_ROOT % 'list_template_functions',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_preview = policy.DeprecatedRule( deprecated_preview = policy.DeprecatedRule(
name=POLICY_ROOT % 'preview', name=POLICY_ROOT % 'preview',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_resource_schema = policy.DeprecatedRule( deprecated_resource_schema = policy.DeprecatedRule(
name=POLICY_ROOT % 'resource_schema', name=POLICY_ROOT % 'resource_schema',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show = policy.DeprecatedRule( deprecated_show = policy.DeprecatedRule(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_template = policy.DeprecatedRule( deprecated_template = policy.DeprecatedRule(
name=POLICY_ROOT % 'template', name=POLICY_ROOT % 'template',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_environment = policy.DeprecatedRule( deprecated_environment = policy.DeprecatedRule(
name=POLICY_ROOT % 'environment', name=POLICY_ROOT % 'environment',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_files = policy.DeprecatedRule( deprecated_files = policy.DeprecatedRule(
name=POLICY_ROOT % 'files', name=POLICY_ROOT % 'files',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_update = policy.DeprecatedRule( deprecated_update = policy.DeprecatedRule(
name=POLICY_ROOT % 'update', name=POLICY_ROOT % 'update',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_update_patch = policy.DeprecatedRule( deprecated_update_patch = policy.DeprecatedRule(
name=POLICY_ROOT % 'update_patch', name=POLICY_ROOT % 'update_patch',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_preview_update = policy.DeprecatedRule( deprecated_preview_update = policy.DeprecatedRule(
name=POLICY_ROOT % 'preview_update', name=POLICY_ROOT % 'preview_update',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_preview_update_patch = policy.DeprecatedRule( deprecated_preview_update_patch = policy.DeprecatedRule(
name=POLICY_ROOT % 'preview_update_patch', name=POLICY_ROOT % 'preview_update_patch',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_validate_template = policy.DeprecatedRule( deprecated_validate_template = policy.DeprecatedRule(
name=POLICY_ROOT % 'validate_template', name=POLICY_ROOT % 'validate_template',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_snapshot = policy.DeprecatedRule( deprecated_snapshot = policy.DeprecatedRule(
name=POLICY_ROOT % 'snapshot', name=POLICY_ROOT % 'snapshot',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show_snapshot = policy.DeprecatedRule( deprecated_show_snapshot = policy.DeprecatedRule(
name=POLICY_ROOT % 'show_snapshot', name=POLICY_ROOT % 'show_snapshot',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_delete_snapshot = policy.DeprecatedRule( deprecated_delete_snapshot = policy.DeprecatedRule(
name=POLICY_ROOT % 'delete_snapshot', name=POLICY_ROOT % 'delete_snapshot',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_list_snapshots = policy.DeprecatedRule( deprecated_list_snapshots = policy.DeprecatedRule(
name=POLICY_ROOT % 'list_snapshots', name=POLICY_ROOT % 'list_snapshots',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_restore_snapshot = policy.DeprecatedRule( deprecated_restore_snapshot = policy.DeprecatedRule(
name=POLICY_ROOT % 'restore_snapshot', name=POLICY_ROOT % 'restore_snapshot',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_list_outputs = policy.DeprecatedRule( deprecated_list_outputs = policy.DeprecatedRule(
name=POLICY_ROOT % 'list_outputs', name=POLICY_ROOT % 'list_outputs',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_show_output = policy.DeprecatedRule( deprecated_show_output = policy.DeprecatedRule(
name=POLICY_ROOT % 'show_output', name=POLICY_ROOT % 'show_output',
check_str=base.RULE_DENY_STACK_USER check_str=base.RULE_DENY_STACK_USER,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
deprecated_lookup = policy.DeprecatedRule( deprecated_lookup = policy.DeprecatedRule(
name=POLICY_ROOT % 'lookup', name=POLICY_ROOT % 'lookup',
check_str=base.RULE_ALLOW_EVERYBODY check_str=base.RULE_ALLOW_EVERYBODY,
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
@ -156,9 +216,7 @@ stacks_policies = [
'method': 'DELETE' 'method': 'DELETE'
} }
], ],
deprecated_rule=deprecated_abandon, deprecated_rule=deprecated_abandon
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'create', name=POLICY_ROOT % 'create',
@ -171,9 +229,7 @@ stacks_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_create, deprecated_rule=deprecated_create
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'delete', name=POLICY_ROOT % 'delete',
@ -186,9 +242,7 @@ stacks_policies = [
'method': 'DELETE' 'method': 'DELETE'
} }
], ],
deprecated_rule=deprecated_delete, deprecated_rule=deprecated_delete
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'detail', name=POLICY_ROOT % 'detail',
@ -201,9 +255,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_detail, deprecated_rule=deprecated_detail
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'export', name=POLICY_ROOT % 'export',
@ -217,9 +269,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_export, deprecated_rule=deprecated_export
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'generate_template', name=POLICY_ROOT % 'generate_template',
@ -233,9 +283,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_generate_template, deprecated_rule=deprecated_generate_template
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'global_index', name=POLICY_ROOT % 'global_index',
@ -248,9 +296,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_global_index, deprecated_rule=deprecated_global_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'index', name=POLICY_ROOT % 'index',
@ -263,9 +309,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_index, deprecated_rule=deprecated_index
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'list_resource_types', name=POLICY_ROOT % 'list_resource_types',
@ -278,9 +322,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_list_resource_types, deprecated_rule=deprecated_list_resource_types
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'list_template_versions', name=POLICY_ROOT % 'list_template_versions',
@ -293,9 +335,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_list_template_versions, deprecated_rule=deprecated_list_template_versions
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'list_template_functions', name=POLICY_ROOT % 'list_template_functions',
@ -309,9 +349,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_list_template_functions, deprecated_rule=deprecated_list_template_functions
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'lookup', name=POLICY_ROOT % 'lookup',
@ -324,9 +362,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_lookup, deprecated_rule=deprecated_lookup
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'preview', name=POLICY_ROOT % 'preview',
@ -339,9 +375,7 @@ stacks_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_preview, deprecated_rule=deprecated_preview
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'resource_schema', name=POLICY_ROOT % 'resource_schema',
@ -354,9 +388,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_resource_schema, deprecated_rule=deprecated_resource_schema
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show', name=POLICY_ROOT % 'show',
@ -369,9 +401,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show, deprecated_rule=deprecated_show
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'template', name=POLICY_ROOT % 'template',
@ -385,9 +415,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_template, deprecated_rule=deprecated_template
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'environment', name=POLICY_ROOT % 'environment',
@ -401,9 +429,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_environment, deprecated_rule=deprecated_environment
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'files', name=POLICY_ROOT % 'files',
@ -417,9 +443,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_files, deprecated_rule=deprecated_files
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'update', name=POLICY_ROOT % 'update',
@ -432,9 +456,7 @@ stacks_policies = [
'method': 'PUT' 'method': 'PUT'
} }
], ],
deprecated_rule=deprecated_update, deprecated_rule=deprecated_update
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'update_patch', name=POLICY_ROOT % 'update_patch',
@ -447,9 +469,7 @@ stacks_policies = [
'method': 'PATCH' 'method': 'PATCH'
} }
], ],
deprecated_rule=deprecated_update_patch, deprecated_rule=deprecated_update_patch
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'preview_update', name=POLICY_ROOT % 'preview_update',
@ -463,9 +483,7 @@ stacks_policies = [
'method': 'PUT' 'method': 'PUT'
} }
], ],
deprecated_rule=deprecated_preview_update, deprecated_rule=deprecated_preview_update
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'preview_update_patch', name=POLICY_ROOT % 'preview_update_patch',
@ -479,9 +497,7 @@ stacks_policies = [
'method': 'PATCH' 'method': 'PATCH'
} }
], ],
deprecated_rule=deprecated_preview_update_patch, deprecated_rule=deprecated_preview_update_patch
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'validate_template', name=POLICY_ROOT % 'validate_template',
@ -494,9 +510,7 @@ stacks_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_validate_template, deprecated_rule=deprecated_validate_template
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'snapshot', name=POLICY_ROOT % 'snapshot',
@ -510,9 +524,7 @@ stacks_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_snapshot, deprecated_rule=deprecated_snapshot
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show_snapshot', name=POLICY_ROOT % 'show_snapshot',
@ -526,9 +538,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show_snapshot, deprecated_rule=deprecated_show_snapshot
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'delete_snapshot', name=POLICY_ROOT % 'delete_snapshot',
@ -542,9 +552,7 @@ stacks_policies = [
'method': 'DELETE' 'method': 'DELETE'
} }
], ],
deprecated_rule=deprecated_delete_snapshot, deprecated_rule=deprecated_delete_snapshot
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'list_snapshots', name=POLICY_ROOT % 'list_snapshots',
@ -558,9 +566,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_list_snapshots, deprecated_rule=deprecated_list_snapshots
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'restore_snapshot', name=POLICY_ROOT % 'restore_snapshot',
@ -574,9 +580,7 @@ stacks_policies = [
'method': 'POST' 'method': 'POST'
} }
], ],
deprecated_rule=deprecated_restore_snapshot, deprecated_rule=deprecated_restore_snapshot
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'list_outputs', name=POLICY_ROOT % 'list_outputs',
@ -590,9 +594,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_list_outputs, deprecated_rule=deprecated_list_outputs
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
), ),
policy.DocumentedRuleDefault( policy.DocumentedRuleDefault(
name=POLICY_ROOT % 'show_output', name=POLICY_ROOT % 'show_output',
@ -606,9 +608,7 @@ stacks_policies = [
'method': 'GET' 'method': 'GET'
} }
], ],
deprecated_rule=deprecated_show_output, deprecated_rule=deprecated_show_output
deprecated_reason=DEPRECATED_REASON,
deprecated_since=versionutils.deprecated.WALLABY
) )
] ]

View File

@ -73,7 +73,7 @@ oslo.i18n==3.20.0
oslo.log==4.3.0 oslo.log==4.3.0
oslo.messaging==5.29.0 oslo.messaging==5.29.0
oslo.middleware==3.31.0 oslo.middleware==3.31.0
oslo.policy==3.6.2 oslo.policy==3.7.0
oslo.reports==1.18.0 oslo.reports==1.18.0
oslo.serialization==2.25.0 oslo.serialization==2.25.0
oslo.service==1.24.0 oslo.service==1.24.0

View File

@ -24,7 +24,7 @@ oslo.i18n>=3.20.0 # Apache-2.0
oslo.log>=4.3.0 # Apache-2.0 oslo.log>=4.3.0 # Apache-2.0
oslo.messaging>=5.29.0 # Apache-2.0 oslo.messaging>=5.29.0 # Apache-2.0
oslo.middleware>=3.31.0 # Apache-2.0 oslo.middleware>=3.31.0 # Apache-2.0
oslo.policy>=3.6.2 # Apache-2.0 oslo.policy>=3.7.0 # Apache-2.0
oslo.reports>=1.18.0 # Apache-2.0 oslo.reports>=1.18.0 # Apache-2.0
oslo.serialization>=2.25.0 # Apache-2.0 oslo.serialization>=2.25.0 # Apache-2.0
oslo.service!=1.28.1,>=1.24.0 # Apache-2.0 oslo.service!=1.28.1,>=1.24.0 # Apache-2.0