Last active
October 30, 2020 09:23
-
-
Save vvucetic/1b29a79e97c34fdf19a81ce314c43ffd to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Resources: | |
| RateLimitACL: | |
| Type: AWS::WAFv2::WebACL | |
| Properties: | |
| Name: rate-limit-acl | |
| Scope: REGIONAL | |
| Description: Auto-generated rate-limiting ACL. | |
| DefaultAction: | |
| Allow: {} | |
| VisibilityConfig: | |
| SampledRequestsEnabled: true | |
| CloudWatchMetricsEnabled: true | |
| MetricName: rate-limit-acl | |
| Rules: | |
| - Name: rate-limit-bar | |
| Priority: 1 | |
| Action: | |
| Block: {} | |
| VisibilityConfig: | |
| SampledRequestsEnabled: true | |
| CloudWatchMetricsEnabled: true | |
| MetricName: rate-limit-bar | |
| Statement: | |
| RateBasedStatement: | |
| AggregateKeyType: "IP" | |
| Limit: 100 | |
| ScopeDownStatement: | |
| ByteMatchStatement: | |
| SearchString: "/bar/" | |
| FieldToMatch: | |
| UriPath: {} | |
| TextTransformations: | |
| - Type: URL_DECODE | |
| Priority: 0 | |
| PositionalConstraint: "STARTS_WITH" | |
| - Name: allow-bar | |
| Priority: 2 | |
| Action: | |
| Allow: {} | |
| VisibilityConfig: | |
| SampledRequestsEnabled: true | |
| CloudWatchMetricsEnabled: true | |
| MetricName: allow-bar | |
| Statement: | |
| ByteMatchStatement: | |
| SearchString: "/bar/" | |
| FieldToMatch: | |
| UriPath: {} | |
| TextTransformations: | |
| - Type: URL_DECODE | |
| Priority: 0 | |
| PositionalConstraint: "STARTS_WITH" | |
| - Name: rate-limit-foo | |
| Priority: 3 | |
| Action: | |
| Block: {} | |
| VisibilityConfig: | |
| SampledRequestsEnabled: true | |
| CloudWatchMetricsEnabled: true | |
| MetricName: rate-limit-foo | |
| Statement: | |
| RateBasedStatement: | |
| AggregateKeyType: "IP" | |
| Limit: 500 | |
| ScopeDownStatement: | |
| ByteMatchStatement: | |
| SearchString: "/foo/" | |
| FieldToMatch: | |
| UriPath: {} | |
| TextTransformations: | |
| - Type: URL_DECODE | |
| Priority: 0 | |
| PositionalConstraint: "STARTS_WITH" | |
| - Name: allow-foo | |
| Priority: 4 | |
| Action: | |
| Allow: {} | |
| VisibilityConfig: | |
| SampledRequestsEnabled: true | |
| CloudWatchMetricsEnabled: true | |
| MetricName: allow-foo | |
| Statement: | |
| ByteMatchStatement: | |
| SearchString: "/foo/" | |
| FieldToMatch: | |
| UriPath: {} | |
| TextTransformations: | |
| - Type: URL_DECODE | |
| Priority: 0 | |
| PositionalConstraint: "STARTS_WITH" | |
| - Name: rate-limit-other | |
| Priority: 5 | |
| Action: | |
| Count: {} | |
| VisibilityConfig: | |
| SampledRequestsEnabled: true | |
| CloudWatchMetricsEnabled: true | |
| MetricName: rate-limit-other | |
| Statement: | |
| RateBasedStatement: | |
| AggregateKeyType: "IP" | |
| Limit: 300 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment