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 |
Creates a RegexPatternSet
. You then use UpdateRegexPatternSet
to specify the regular expression (regex) pattern that you want AWS WAF to search for, such as B[a
]dB[o0]t@ . You can then configure AWS WAF to reject those requests.
To create and configure a RegexPatternSet
, perform the following steps:
- Use
GetChangeToken
to get the change token that you provide in theChangeToken
parameter of aCreateRegexPatternSet
request. - Submit a
CreateRegexPatternSet
request. - Use
GetChangeToken
to get the change token that you provide in theChangeToken
parameter of anUpdateRegexPatternSet
request. - Submit an
UpdateRegexPatternSet
request to specify the string 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
- createRegexPatternSet :: Text -> Text -> CreateRegexPatternSet
- data CreateRegexPatternSet
- crpsName :: Lens' CreateRegexPatternSet Text
- crpsChangeToken :: Lens' CreateRegexPatternSet Text
- createRegexPatternSetResponse :: Int -> CreateRegexPatternSetResponse
- data CreateRegexPatternSetResponse
- crpsrsRegexPatternSet :: Lens' CreateRegexPatternSetResponse (Maybe RegexPatternSet)
- crpsrsChangeToken :: Lens' CreateRegexPatternSetResponse (Maybe Text)
- crpsrsResponseStatus :: Lens' CreateRegexPatternSetResponse Int
Creating a Request
createRegexPatternSet Source #
Creates a value of CreateRegexPatternSet
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
crpsName
- A friendly name or description of theRegexPatternSet
. You can't changeName
after you create aRegexPatternSet
.crpsChangeToken
- The value returned by the most recent call toGetChangeToken
.
data CreateRegexPatternSet Source #
See: createRegexPatternSet
smart constructor.
Instances
Request Lenses
crpsName :: Lens' CreateRegexPatternSet Text Source #
A friendly name or description of the RegexPatternSet
. You can't change Name
after you create a RegexPatternSet
.
crpsChangeToken :: Lens' CreateRegexPatternSet Text Source #
The value returned by the most recent call to GetChangeToken
.
Destructuring the Response
createRegexPatternSetResponse Source #
Creates a value of CreateRegexPatternSetResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
crpsrsRegexPatternSet
- ARegexPatternSet
that contains no objects.crpsrsChangeToken
- TheChangeToken
that you used to submit theCreateRegexPatternSet
request. You can also use this value to query the status of the request. For more information, seeGetChangeTokenStatus
.crpsrsResponseStatus
- -- | The response status code.
data CreateRegexPatternSetResponse Source #
See: createRegexPatternSetResponse
smart constructor.
Instances
Response Lenses
crpsrsRegexPatternSet :: Lens' CreateRegexPatternSetResponse (Maybe RegexPatternSet) Source #
A RegexPatternSet
that contains no objects.
crpsrsChangeToken :: Lens' CreateRegexPatternSetResponse (Maybe Text) Source #
The ChangeToken
that you used to submit the CreateRegexPatternSet
request. You can also use this value to query the status of the request. For more information, see GetChangeTokenStatus
.
crpsrsResponseStatus :: Lens' CreateRegexPatternSetResponse Int Source #
- - | The response status code.