Skip to content

Ensure Routing Table associated with Web tier subnet have the default route (0.0.0.0/0) defined to allow connectivity

Description

This policy checks if a route table associated with a web tier subnet has a default route (0.0.0.0/0) defined to allow connectivity through a NAT gateway. The default route is essential for enabling internet access for instances in the subnet. Without it, instances may not be able to connect to the internet, potentially disrupting application functionality. It's crucial to ensure the default route is correctly configured to maintain connectivity.

Code Example

terraform
resource "ncloud_route" "example" {
  destination_cidr_block = "0.0.0.0/0"
  target_type = "NATGW"
}

Remediation

Update the route table configuration to include the default route (0.0.0.0/0) with the target type set to NATGW.

Rule Details

FieldValue
IDIAC-1222
SeverityMEDIUM
IaC TypeTerraform
Frameworksncloud_route
Checkov IDCKV_NCP_20

References