Nifcloud ELB Has Common Private Network

  • Query id: 5061f84c-ab66-4660-90b9-680c9df346c0
  • Query name: Nifcloud ELB Has Common Private Network
  • Platform: Terraform
  • Severity: Low
  • Category: Networking and Firewall
  • CWE: 285
  • URL: Github

Description

The ELB has common private network
Documentation

Code samples

Code samples with security vulnerabilities

Positive test num. 1 - tf file
resource "nifcloud_elb" "positive" {
  availability_zone = "east-11"
  instance_port     = 80
  protocol          = "HTTP"
  lb_port           = 80
  network_interface {
    network_id = "net-COMMON_PRIVATE"
  }
}
Positive test num. 2 - tf file
resource "nifcloud_elb" "positive" {
  availability_zone = "east-11"
  instance_port     = 80
  protocol          = "HTTP"
  lb_port           = 80
  network_interface {
    network_id = "net-COMMON_GLOBAL"
  }
  network_interface {
    network_id = "net-COMMON_PRIVATE"
  }
}

Code samples without security vulnerabilities

Negative test num. 1 - tf file
resource "nifcloud_elb" "negative" {
  availability_zone = "east-11"
  instance_port     = 80
  protocol          = "HTTP"
  lb_port           = 80
  network_interface {
    network_id = nifcloud_private_lan.main.id
  }
}