amazonka-waf-1.6.0: Amazon WAF SDK.

Copyright(c) 2013-2018 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.WAF.PutPermissionPolicy

Contents

Description

Attaches a IAM policy to the specified resource. The only supported use for this action is to share a RuleGroup across accounts.

The PutPermissionPolicy is subject to the following restrictions:

  • You can attach only one policy with each PutPermissionPolicy request.
  • The policy must include an Effect , Action and Principal .
  • Effect must specify Allow .
  • The Action in the policy must be waf:UpdateWebACL and waf-regional:UpdateWebACL . Any extra or wildcard actions in the policy will be rejected.
  • The policy cannot include a Resource parameter.
  • The ARN in the request must be a valid WAF RuleGroup ARN and the RuleGroup must exist in the same region.
  • The user making the request must be the owner of the RuleGroup.
  • Your policy must be composed using IAM Policy version 2012-10-17.

For more information, see IAM Policies .

An example of a valid policy parameter is shown in the Examples section below.

Synopsis

Creating a Request

putPermissionPolicy #

Creates a value of PutPermissionPolicy with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • pppResourceARN - The Amazon Resource Name (ARN) of the RuleGroup to which you want to attach the policy.
  • pppPolicy - The policy to attach to the specified RuleGroup.

data PutPermissionPolicy #

See: putPermissionPolicy smart constructor.

Instances

Eq PutPermissionPolicy # 
Data PutPermissionPolicy # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutPermissionPolicy -> c PutPermissionPolicy #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutPermissionPolicy #

toConstr :: PutPermissionPolicy -> Constr #

dataTypeOf :: PutPermissionPolicy -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutPermissionPolicy) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutPermissionPolicy) #

gmapT :: (forall b. Data b => b -> b) -> PutPermissionPolicy -> PutPermissionPolicy #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutPermissionPolicy -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutPermissionPolicy -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutPermissionPolicy -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutPermissionPolicy -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutPermissionPolicy -> m PutPermissionPolicy #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermissionPolicy -> m PutPermissionPolicy #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermissionPolicy -> m PutPermissionPolicy #

Read PutPermissionPolicy # 
Show PutPermissionPolicy # 
Generic PutPermissionPolicy # 
Hashable PutPermissionPolicy # 
ToJSON PutPermissionPolicy # 
NFData PutPermissionPolicy # 

Methods

rnf :: PutPermissionPolicy -> () #

AWSRequest PutPermissionPolicy # 
ToHeaders PutPermissionPolicy # 
ToPath PutPermissionPolicy # 
ToQuery PutPermissionPolicy # 
type Rep PutPermissionPolicy # 
type Rep PutPermissionPolicy = D1 * (MetaData "PutPermissionPolicy" "Network.AWS.WAF.PutPermissionPolicy" "amazonka-waf-1.6.0-K7okww4xWnpBRydji27mKc" False) (C1 * (MetaCons "PutPermissionPolicy'" PrefixI True) ((:*:) * (S1 * (MetaSel (Just Symbol "_pppResourceARN") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text)) (S1 * (MetaSel (Just Symbol "_pppPolicy") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text))))
type Rs PutPermissionPolicy # 

Request Lenses

pppResourceARN :: Lens' PutPermissionPolicy Text #

The Amazon Resource Name (ARN) of the RuleGroup to which you want to attach the policy.

pppPolicy :: Lens' PutPermissionPolicy Text #

The policy to attach to the specified RuleGroup.

Destructuring the Response

putPermissionPolicyResponse #

Creates a value of PutPermissionPolicyResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data PutPermissionPolicyResponse #

See: putPermissionPolicyResponse smart constructor.

Instances

Eq PutPermissionPolicyResponse # 
Data PutPermissionPolicyResponse # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> PutPermissionPolicyResponse -> c PutPermissionPolicyResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c PutPermissionPolicyResponse #

toConstr :: PutPermissionPolicyResponse -> Constr #

dataTypeOf :: PutPermissionPolicyResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c PutPermissionPolicyResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c PutPermissionPolicyResponse) #

gmapT :: (forall b. Data b => b -> b) -> PutPermissionPolicyResponse -> PutPermissionPolicyResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> PutPermissionPolicyResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> PutPermissionPolicyResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> PutPermissionPolicyResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> PutPermissionPolicyResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> PutPermissionPolicyResponse -> m PutPermissionPolicyResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermissionPolicyResponse -> m PutPermissionPolicyResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> PutPermissionPolicyResponse -> m PutPermissionPolicyResponse #

Read PutPermissionPolicyResponse # 
Show PutPermissionPolicyResponse # 
Generic PutPermissionPolicyResponse # 
NFData PutPermissionPolicyResponse # 
type Rep PutPermissionPolicyResponse # 
type Rep PutPermissionPolicyResponse = D1 * (MetaData "PutPermissionPolicyResponse" "Network.AWS.WAF.PutPermissionPolicy" "amazonka-waf-1.6.0-K7okww4xWnpBRydji27mKc" True) (C1 * (MetaCons "PutPermissionPolicyResponse'" PrefixI True) (S1 * (MetaSel (Just Symbol "_ppprsResponseStatus") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (Rec0 * Int)))

Response Lenses