WAFV2 / Client / exceptions / WAFInvalidPermissionPolicyException
WAFInvalidPermissionPolicyException#
- class WAFV2.Client.exceptions.WAFInvalidPermissionPolicyException#
The operation failed because the specified policy isn’t in the proper format.
The policy specifications must conform to the following:
The policy must be composed using IAM Policy version 2012-10-17.
The policy must include specifications for
Effect
,Action
, andPrincipal
.Effect
must specifyAllow
.Action
must specifywafv2:CreateWebACL
,wafv2:UpdateWebACL
, andwafv2:PutFirewallManagerRuleGroups
and may optionally specifywafv2:GetRuleGroup
. WAF rejects any extra actions or wildcard actions in the policy.The policy must not include a
Resource
parameter.
For more information, see IAM Policies.
Example
try: ... except client.exceptions.WAFInvalidPermissionPolicyException as e: print(e.response)
- response#
The parsed error response. All exceptions have a top level
Error
key that provides normalized access to common exception atrributes. All other keys are specific to this service or exception class.Syntax
{ 'Message': 'string', 'Error': { 'Code': 'string', 'Message': 'string' } }
Structure
(dict) –
The operation failed because the specified policy isn’t in the proper format.
The policy specifications must conform to the following:
The policy must be composed using IAM Policy version 2012-10-17.
The policy must include specifications for
Effect
,Action
, andPrincipal
.Effect
must specifyAllow
.Action
must specifywafv2:CreateWebACL
,wafv2:UpdateWebACL
, andwafv2:PutFirewallManagerRuleGroups
and may optionally specifywafv2:GetRuleGroup
. WAF rejects any extra actions or wildcard actions in the policy.The policy must not include a
Resource
parameter.
For more information, see IAM Policies.
Message (string) –
Error (dict) – Normalized access to common exception attributes.
Code (string) – An identifier specifying the exception type.
Message (string) – A descriptive message explaining why the exception occured.