| Copyright | (c) 2013-2018 Brendan Hay |
|---|---|
| License | Mozilla Public License, v. 2.0. |
| Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
| Stability | auto-generated |
| Portability | non-portable (GHC extensions) |
| Safe Haskell | None |
| Language | Haskell2010 |
Network.AWS.WAF.CreateGeoMatchSet
Description
Creates an GeoMatchSet , which you use to specify which web requests you want to allow or block based on the country that the requests originate from. For example, if you're receiving a lot of requests from one or more countries and you want to block the requests, you can create an GeoMatchSet that contains those countries and then configure AWS WAF to block the requests.
To create and configure a GeoMatchSet , perform the following steps:
- Use
GetChangeTokento get the change token that you provide in theChangeTokenparameter of aCreateGeoMatchSetrequest. - Submit a
CreateGeoMatchSetrequest. - Use
GetChangeTokento get the change token that you provide in theChangeTokenparameter of anUpdateGeoMatchSetrequest. - Submit an
UpdateGeoMatchSetSetrequest to specify the countries that you want AWS WAF to watch for.
For more information about how to use the AWS WAF API to allow or block HTTP requests, see the AWS WAF Developer Guide .
Synopsis
- createGeoMatchSet :: Text -> Text -> CreateGeoMatchSet
- data CreateGeoMatchSet
- cgmsName :: Lens' CreateGeoMatchSet Text
- cgmsChangeToken :: Lens' CreateGeoMatchSet Text
- createGeoMatchSetResponse :: Int -> CreateGeoMatchSetResponse
- data CreateGeoMatchSetResponse
- cgmsrsGeoMatchSet :: Lens' CreateGeoMatchSetResponse (Maybe GeoMatchSet)
- cgmsrsChangeToken :: Lens' CreateGeoMatchSetResponse (Maybe Text)
- cgmsrsResponseStatus :: Lens' CreateGeoMatchSetResponse Int
Creating a Request
Arguments
| :: Text | |
| -> Text | |
| -> CreateGeoMatchSet |
Creates a value of CreateGeoMatchSet with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
cgmsName- A friendly name or description of theGeoMatchSet. You can't changeNameafter you create theGeoMatchSet.cgmsChangeToken- The value returned by the most recent call toGetChangeToken.
data CreateGeoMatchSet Source #
See: createGeoMatchSet smart constructor.
Instances
Request Lenses
cgmsName :: Lens' CreateGeoMatchSet Text Source #
A friendly name or description of the GeoMatchSet . You can't change Name after you create the GeoMatchSet .
cgmsChangeToken :: Lens' CreateGeoMatchSet Text Source #
The value returned by the most recent call to GetChangeToken .
Destructuring the Response
createGeoMatchSetResponse Source #
Arguments
| :: Int | |
| -> CreateGeoMatchSetResponse |
Creates a value of CreateGeoMatchSetResponse with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
cgmsrsGeoMatchSet- TheGeoMatchSetreturned in theCreateGeoMatchSetresponse. TheGeoMatchSetcontains noGeoMatchConstraints.cgmsrsChangeToken- TheChangeTokenthat you used to submit theCreateGeoMatchSetrequest. You can also use this value to query the status of the request. For more information, seeGetChangeTokenStatus.cgmsrsResponseStatus- -- | The response status code.
data CreateGeoMatchSetResponse Source #
See: createGeoMatchSetResponse smart constructor.
Instances
Response Lenses
cgmsrsGeoMatchSet :: Lens' CreateGeoMatchSetResponse (Maybe GeoMatchSet) Source #
The GeoMatchSet returned in the CreateGeoMatchSet response. The GeoMatchSet contains no GeoMatchConstraints .
cgmsrsChangeToken :: Lens' CreateGeoMatchSetResponse (Maybe Text) Source #
The ChangeToken that you used to submit the CreateGeoMatchSet request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus .
cgmsrsResponseStatus :: Lens' CreateGeoMatchSetResponse Int Source #
- - | The response status code.