resource "aws_network_acl" "acl-005274ee31d47fe8a" {
  #checkov:skip=CKV2_AWS_1: Ensure that all NACL are attached to subnets
  egress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "1"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.0.0.0/8"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "5"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.108.0/27"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "8"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.177.128/25"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "2"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.12.246.0/25"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "4"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.250.25.192/26"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "3"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "162.49.0.0/16"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "6"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "192.168.0.0/16"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "7"
    to_port    = "0"
  }

  subnet_ids = ["subnet-050c95ced9aedba62"]

  tags = {
    Business-unit = "Global-DS"
    Environment   = "DEV"
    Name          = "GDS-D1-RDS-NACL"
    Owner         = "Dave Wenger"
    Project-code  = "SME-GLOBAL-DS"
    Project-name  = "Global-DS-MSK"
  }

  tags_all = {
    Business-unit = "Global-DS"
    Environment   = "DEV"
    Name          = "GDS-D1-RDS-NACL"
    Owner         = "Dave Wenger"
    Project-code  = "SME-GLOBAL-DS"
    Project-name  = "Global-DS-MSK"
  }

  vpc_id = "vpc-0b6089ab2eda0058f"
}

resource "aws_network_acl" "acl-012b98af38432cabd" {
  #checkov:skip=CKV2_AWS_1: Ensure that all NACL are attached to subnets
  #checkov:skip=CKV_AWS_231: Ensure no NACL allow ingress from 0.0.0.0:0 to port 3389
  egress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "1"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "17"
    rule_no    = "4"
    to_port    = "65535"
  }

  ingress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "1024"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "3"
    to_port    = "65535"
  }

  ingress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "2"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.0.0.0/8"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "5"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.0.0.0/8"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "7"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.108.0/27"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "8"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.250.25.192/26"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "6"
    to_port    = "0"
  }

  subnet_ids = ["subnet-0181b857c79929c1a", "subnet-06ceb7f30790a0756", "subnet-07868af0ad7b6496f", "subnet-084962a4efb61e6b7", "subnet-0c13faff97d006092", "subnet-0f3569bda722376b9"]

  tags = {
    Business-unit = "Global-DS"
    Environment   = "DEV"
    Name          = "GDS-D1-PUB-NACL"
    Owner         = "Dave Wenger"
    Project-code  = "SME-GLOBAL-DS"
    Project-name  = "Global-DS-MSK"
  }

  tags_all = {
    Business-unit = "Global-DS"
    Environment   = "DEV"
    Name          = "GDS-D1-PUB-NACL"
    Owner         = "Dave Wenger"
    Project-code  = "SME-GLOBAL-DS"
    Project-name  = "Global-DS-MSK"
  }

  vpc_id = "vpc-0b6089ab2eda0058f"
}

resource "aws_network_acl" "acl-0743e89e6bf00c232" {
  #checkov:skip=CKV2_AWS_1: Ensure that all NACL are attached to subnets
  #checkov:skip=CKV_AWS_231: Ensure no NACL allow ingress from 0.0.0.0:0 to port 3389
  egress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "1"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "17"
    rule_no    = "6"
    to_port    = "65535"
  }

  ingress {
    action     = "allow"
    cidr_block = "0.0.0.0/0"
    from_port  = "1024"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "5"
    to_port    = "65535"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.0.0.0/8"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "2"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.0.0.0/8"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "9"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.0.0.0/8"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "12"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.108.0/27"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "20"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.114.0/25"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "16"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.114.54/32"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "15"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.11.177.128/25"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "7"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.12.246.0/25"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "8"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.250.0.0/16"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "19"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "10.250.6.0/24"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "17"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "162.49.0.0/16"
    from_port  = "22"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "3"
    to_port    = "22"
  }

  ingress {
    action     = "allow"
    cidr_block = "162.49.0.0/16"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "13"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "162.49.0.0/16"
    from_port  = "9098"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "10"
    to_port    = "9098"
  }

  ingress {
    action     = "allow"
    cidr_block = "172.34.19.0/25"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "11"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "172.34.23.0/24"
    from_port  = "443"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "18"
    to_port    = "443"
  }

  ingress {
    action     = "allow"
    cidr_block = "192.168.0.0/16"
    from_port  = "0"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "-1"
    rule_no    = "14"
    to_port    = "0"
  }

  ingress {
    action     = "allow"
    cidr_block = "192.168.0.0/16"
    from_port  = "22"
    icmp_code  = "0"
    icmp_type  = "0"
    protocol   = "6"
    rule_no    = "4"
    to_port    = "22"
  }

  subnet_ids = ["subnet-003432a4daa922d54", "subnet-076ad8f402b6fade0", "subnet-07eb6204b67b62100", "subnet-08ae2ed4a0ca2fe4b", "subnet-08dcd30a6777e4100", "subnet-0922d3f52ad65ed01", "subnet-0a379fc948b1fb2e5", "subnet-0cfe0f2165a322e28", "subnet-0eb313472eb7c49bc", "subnet-0d09af348cd9a0226"]

  tags = {
    Business-unit = "Global-DS"
    Environment   = "DEV"
    Name          = "GDS-D1-APP-NACL"
    Owner         = "Dave Wenger"
    Project-code  = "SME-GLOBAL-DS"
    Project-name  = "Global-DS-MSK"
  }

  tags_all = {
    Business-unit = "Global-DS"
    Environment   = "DEV"
    Name          = "GDS-D1-APP-NACL"
    Owner         = "Dave Wenger"
    Project-code  = "SME-GLOBAL-DS"
    Project-name  = "Global-DS-MSK"
  }

  vpc_id = "vpc-0b6089ab2eda0058f"
}

resource "aws_network_acl" "acl-0d95046f4ddb25a4f" {
  #checkov:skip=CKV2_AWS_1: Ensure that all NACL are attached to subnets
  tags = {
    Name = "GDS-D1-DEFAULT-NACL"
  }

  tags_all = {
    Name = "GDS-D1-DEFAULT-NACL"
  }

  vpc_id = "vpc-0b6089ab2eda0058f"
}
