Default network automatically created Affecting Cloud Platform service in Google


0.0
medium
0
10
    Severity Framework Snyk CCSS
    Rule category General / Admin Activities

Is your enviroment affected by this misconfiguration?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
    Frameworks
    CIS-Controls CSA-CCM ISO-27001 NIST-800-53 PCI-DSS SOC-2
  • Snyk ID SNYK-CC-00405
  • credit Snyk Research Team

Description

Default network will be automatically created for the project.

How to fix?

Set auto_create_network attribute to false.

Example Configuration

resource "google_project" "project-allowed" {
  name                = "project-g-405"
  project_id          = "project-id-g-405"
  auto_create_network = false
  billing_account  = "01A182-E5EB48-AA7FB2"
}

resource "google_project_service" "compute" {
  service ="compute.googleapis.com"  
  project    = google_project.project-allowed.project_id
  depends_on = ["google_project.project-allowed"]
}

Terraform