amazonka-waf-1.4.5: Amazon WAF SDK.

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

Network.AWS.WAF.UpdateWebACL

Contents

Description

Inserts or deletes ActivatedRule objects in a WebACL . Each Rule identifies web requests that you want to allow, block, or count. When you update a WebACL , you specify the following values:

  • A default action for the WebACL , either ALLOW or BLOCK . AWS WAF performs the default action if a request doesn't match the criteria in any of the Rules in a WebACL .
  • The Rules that you want to add and/or delete. If you want to replace one Rule with another, you delete the existing Rule and add the new one.
  • For each Rule , whether you want AWS WAF to allow requests, block requests, or count requests that match the conditions in the Rule .
  • The order in which you want AWS WAF to evaluate the Rules in a WebACL . If you add more than one Rule to a WebACL , AWS WAF evaluates each request against the Rules in order based on the value of Priority . (The Rule that has the lowest value for Priority is evaluated first.) When a web request matches all of the predicates (such as ByteMatchSets and IPSets ) in a Rule , AWS WAF immediately takes the corresponding action, allow or block, and doesn't evaluate the request against the remaining Rules in the WebACL , if any.
  • The CloudFront distribution that you want to associate with the WebACL .

To create and configure a WebACL , perform the following steps:

  • Create and update the predicates that you want to include in Rules . For more information, see CreateByteMatchSet , UpdateByteMatchSet , CreateIPSet , UpdateIPSet , CreateSqlInjectionMatchSet , and UpdateSqlInjectionMatchSet .
  • Create and update the Rules that you want to include in the WebACL . For more information, see CreateRule and UpdateRule .
  • Create a WebACL . See CreateWebACL .
  • Use GetChangeToken to get the change token that you provide in the ChangeToken parameter of an UpdateWebACL request.
  • Submit an UpdateWebACL request to specify the Rules that you want to include in the WebACL , to specify the default action, and to associate the WebACL with a CloudFront distribution.

For more information about how to use the AWS WAF API to allow or block HTTP requests, see the AWS WAF Developer Guide .

Synopsis

Creating a Request

updateWebACL Source #

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

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

  • uwaUpdates - An array of updates to make to the WebACL . An array of WebACLUpdate objects that you want to insert into or delete from a WebACL . For more information, see the applicable data types: * WebACLUpdate : Contains Action and ActivatedRule * ActivatedRule : Contains Action , Priority , and RuleId * WafAction : Contains Type
  • uwaDefaultAction - Undocumented member.
  • uwaWebACLId - The WebACLId of the WebACL that you want to update. WebACLId is returned by CreateWebACL and by ListWebACLs .
  • uwaChangeToken - The value returned by the most recent call to GetChangeToken .

data UpdateWebACL Source #

See: updateWebACL smart constructor.

Instances

Eq UpdateWebACL Source # 
Data UpdateWebACL Source # 

Methods

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

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

toConstr :: UpdateWebACL -> Constr #

dataTypeOf :: UpdateWebACL -> DataType #

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

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

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

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

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

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

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

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

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

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

Read UpdateWebACL Source # 
Show UpdateWebACL Source # 
Generic UpdateWebACL Source # 

Associated Types

type Rep UpdateWebACL :: * -> * #

Hashable UpdateWebACL Source # 
ToJSON UpdateWebACL Source # 
NFData UpdateWebACL Source # 

Methods

rnf :: UpdateWebACL -> () #

AWSRequest UpdateWebACL Source # 
ToPath UpdateWebACL Source # 
ToHeaders UpdateWebACL Source # 
ToQuery UpdateWebACL Source # 
type Rep UpdateWebACL Source # 
type Rep UpdateWebACL = D1 (MetaData "UpdateWebACL" "Network.AWS.WAF.UpdateWebACL" "amazonka-waf-1.4.5-LwyS40mcrMjGU0oCXONgRC" False) (C1 (MetaCons "UpdateWebACL'" PrefixI True) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_uwaUpdates") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe [WebACLUpdate]))) (S1 (MetaSel (Just Symbol "_uwaDefaultAction") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe WafAction)))) ((:*:) (S1 (MetaSel (Just Symbol "_uwaWebACLId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_uwaChangeToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)))))
type Rs UpdateWebACL Source # 

Request Lenses

uwaUpdates :: Lens' UpdateWebACL [WebACLUpdate] Source #

An array of updates to make to the WebACL . An array of WebACLUpdate objects that you want to insert into or delete from a WebACL . For more information, see the applicable data types: * WebACLUpdate : Contains Action and ActivatedRule * ActivatedRule : Contains Action , Priority , and RuleId * WafAction : Contains Type

uwaWebACLId :: Lens' UpdateWebACL Text Source #

The WebACLId of the WebACL that you want to update. WebACLId is returned by CreateWebACL and by ListWebACLs .

uwaChangeToken :: Lens' UpdateWebACL Text Source #

The value returned by the most recent call to GetChangeToken .

Destructuring the Response

updateWebACLResponse Source #

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

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

  • uwarsChangeToken - The ChangeToken that you used to submit the UpdateWebACL request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus .
  • uwarsResponseStatus - -- | The response status code.

data UpdateWebACLResponse Source #

See: updateWebACLResponse smart constructor.

Instances

Eq UpdateWebACLResponse Source # 
Data UpdateWebACLResponse Source # 

Methods

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

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

toConstr :: UpdateWebACLResponse -> Constr #

dataTypeOf :: UpdateWebACLResponse -> DataType #

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

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

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

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

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

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

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

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

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

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

Read UpdateWebACLResponse Source # 
Show UpdateWebACLResponse Source # 
Generic UpdateWebACLResponse Source # 
NFData UpdateWebACLResponse Source # 

Methods

rnf :: UpdateWebACLResponse -> () #

type Rep UpdateWebACLResponse Source # 
type Rep UpdateWebACLResponse = D1 (MetaData "UpdateWebACLResponse" "Network.AWS.WAF.UpdateWebACL" "amazonka-waf-1.4.5-LwyS40mcrMjGU0oCXONgRC" False) (C1 (MetaCons "UpdateWebACLResponse'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_uwarsChangeToken") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) (S1 (MetaSel (Just Symbol "_uwarsResponseStatus") NoSourceUnpackedness SourceStrict DecidedUnpack) (Rec0 Int))))

Response Lenses

uwarsChangeToken :: Lens' UpdateWebACLResponse (Maybe Text) Source #

The ChangeToken that you used to submit the UpdateWebACL request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus .

uwarsResponseStatus :: Lens' UpdateWebACLResponse Int Source #

  • - | The response status code.