Get the list of GCP IPv4 CIDRs.
(self)
| 162 | self.Azure_IPs.append(IPNetwork(result["ip_prefix"])) |
| 163 | |
| 164 | def __get_gcp_ips(self): |
| 165 | """ |
| 166 | Get the list of GCP IPv4 CIDRs. |
| 167 | """ |
| 168 | if self.GCP_IPs is None: |
| 169 | self.GCP_IPs = [] |
| 170 | |
| 171 | gcp_ips_collection = self._mongo_connector.get_gcp_ips_connection() |
| 172 | |
| 173 | results = self._mongo_connector.perform_find_one(gcp_ips_collection, {}) |
| 174 | |
| 175 | if ( |
| 176 | results is not None |
| 177 | and "prefixes" in results |
| 178 | and len(results["prefixes"]) > 0 |
| 179 | ): |
| 180 | for result in results["prefixes"]: |
| 181 | self.GCP_IPs.append(IPNetwork(result["ip_prefix"])) |
| 182 | |
| 183 | def __get_gcp_ipv6s(self): |
| 184 | """ |
no test coverage detected