Skip to content

Commit

Permalink
UML-3227: Count IP Reputation matches #minor (#2539)
Browse files Browse the repository at this point in the history
  • Loading branch information
jay-whitwell authored Mar 5, 2024
1 parent b4fb6c0 commit b028df3
Showing 1 changed file with 26 additions and 3 deletions.
29 changes: 26 additions & 3 deletions terraform/account/region/waf.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,31 @@ resource "aws_wafv2_web_acl" "main" {
}

rule {
name = "AWS-AWSManagedRulesPHPRuleSet"
name = "AWS-AWSManagedRulesAmazonIpReputationList"
priority = 0

override_action {
count {}
}

statement {
managed_rule_group_statement {
name = "AWSManagedRulesAmazonIpReputationList"
vendor_name = "AWS"
}
}

visibility_config {
cloudwatch_metrics_enabled = true
metric_name = "AWS-AWSManagedRulesAmazonIpReputationList"
sampled_requests_enabled = true
}
}

rule {
name = "AWS-AWSManagedRulesPHPRuleSet"
priority = 1

override_action {
none {}
}
Expand All @@ -30,7 +52,7 @@ resource "aws_wafv2_web_acl" "main" {
}
rule {
name = "AWS-AWSManagedRulesKnownBadInputsRuleSet"
priority = 1
priority = 2

override_action {
none {}
Expand All @@ -51,7 +73,7 @@ resource "aws_wafv2_web_acl" "main" {
}
rule {
name = "AWS-AWSManagedRulesCommonRuleSet"
priority = 2
priority = 3

override_action {
none {}
Expand Down Expand Up @@ -79,6 +101,7 @@ resource "aws_wafv2_web_acl" "main" {
sampled_requests_enabled = true
}
}

visibility_config {
cloudwatch_metrics_enabled = true
metric_name = "${var.account_name}-web-acl"
Expand Down

0 comments on commit b028df3

Please sign in to comment.