Although the GCP documentation claims that IPv6 addresses are supported when making firewall rules (https://cloud.google.com/vpc/docs/firewalls) I can't seem to make it happen. From this doc:
- Firewall rules support IPv4 connections. IPv6 connections are also supported in VPC networks that have IPv6 enabled. When specifying a
source for an ingress rule or a destination for an egress rule by
address, you can specify IPv4 or IPv6 addresses or blocks in CIDR
notation.- Each firewall rule can contain either IPv4 or IPv6 ranges, but not both.
However, when I try to create a firewall rule with an IPv6 address, I get an error and it won't let me save it, as shown in the screenshot below.
The example above shows two examples I've tried, but I've tried it with single addresses, with and without CIDR blocks, and so on. And they are all refused. I've confirmed that the VPC subnet has IPv6 enabled.
Am I missing something?
Best Answer
The GUI doesn't work for me either, but I was able to successfully create the firewall rules with an equivalent gcloud command.
To test, I created a new VPC, new subnet and new firewall rule: