More Info:

Ensure legacy networks do not exist for a project.

Risk Level

Medium

Address

Security

Compliance Standards

CISGCP, CBP

Triage and Remediation

Remediation

To remediate the misconfiguration “Legacy Networks Should Not Be Used” in GCP using GCP console, follow the below steps:

  1. Open the GCP console and go to the VPC networks page.
  2. Select the legacy network that you want to remediate.
  3. In the top menu, click “Delete”.
  4. Review the list of resources that will be deleted with the legacy network. If you are sure you want to delete the legacy network and all its resources, click “Delete”.
  5. Repeat this process for all legacy networks in your GCP project.

Alternatively, you can create a new VPC network and migrate your resources to it. To do so, follow the below steps:

  1. Open the GCP console and go to the VPC networks page.
  2. Click “Create VPC network”.
  3. Enter a name for the new VPC network.
  4. Choose a subnet mode and specify the IP range for the new VPC network.
  5. Click “Create”.
  6. Migrate your resources to the new VPC network by updating their network settings to use the new VPC network.

Note: Before deleting a legacy network, make sure that all resources that depend on it have been migrated to the new VPC network.