Skip to content

Commit 4c8d782

Browse files
committed
eli-537 minor changes based on initial review
1 parent 98c2a0a commit 4c8d782

3 files changed

Lines changed: 3 additions & 5 deletions

File tree

infrastructure/stacks/api-layer/variables.tf

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ variable "SPLUNK_HEC_ENDPOINT" {
1212
# WAF deployment environments (list of environment names where WAF should be deployed)
1313
variable "waf_enabled_environments" {
1414
type = list(string)
15-
description = "Environments in which WAF resources are deployed. Adjust to disable in test after evaluation."
15+
description = "Environments in which WAF resources are deployed"
1616
default = ["preprod", "prod"]
1717
}
1818

infrastructure/stacks/api-layer/waf.tf

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
# WAF Web ACL for API Gateway
2-
# Only deployed in production environment for cost optimization
3-
42
resource "aws_wafv2_web_acl" "api_gateway" {
53
count = local.waf_enabled ? 1 : 0
64
name = "${local.workspace}-eligibility-signposting-api-waf"

infrastructure/stacks/api-layer/waf_alarms.tf

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ resource "aws_cloudwatch_metric_alarm" "waf_rate_limit_blocks" {
135135
# Alarm for blocked non-UK requests
136136
# In preprod US is also allowed (for GitHub Actions), so this alarm fires on traffic
137137
# from countries outside GB+US. In prod it fires on anything outside GB.
138-
resource "aws_cloudwatch_metric_alarm" "waf_non_uk_counted" {
138+
resource "aws_cloudwatch_metric_alarm" "waf_non_uk_blocked" {
139139
count = local.waf_enabled ? 1 : 0
140140
alarm_name = "WAF-NonUK-BlockedRequests-${local.workspace}"
141141
alarm_description = "Alerts when non-UK requests are blocked by geo rule - may indicate stolen mTLS cert use from outside UK"
@@ -170,7 +170,7 @@ resource "aws_cloudwatch_metric_alarm" "waf_non_uk_counted" {
170170
resource "aws_cloudwatch_metric_alarm" "waf_all_requests_high" {
171171
count = local.waf_enabled ? 1 : 0
172172
alarm_name = "WAF-AllRequests-High-${local.workspace}"
173-
alarm_description = "Monitors total request volume through WAF"
173+
alarm_description = "Monitors total allowed request volume through WAF"
174174
comparison_operator = "GreaterThanThreshold"
175175
evaluation_periods = 2
176176
metric_name = "AllowedRequests"

0 commit comments

Comments
 (0)