Hello @Harsh Thakor ,
Welcome to Microsoft Q&A Platform. Thank you for reaching out & hope you are doing well.
I understand that you are using Azure Application Gateway V2 with WAF and came across the Warning in the WAF Custom policy that, it can only allow 600 IPs in one custom rule, so you have a few questions regarding same. I've answered them below.
Is there any such restriction?
Yes, there is such a restriction, but it is WAF IP address ranges per match condition.
WAF IP address ranges per match condition:
540 - with CRS 3.1 or lower
600 - with CRS 3.2 or newer
In case if we want to add more IPS what needs to be done?
As mentioned in the limits:
Maximum WAF custom rules that can be configured in a WAF policy is 100. And WAF IP address ranges per match condition in one custom rule is 600.
So, that gives you a total of 60000 IP address ranges.
If one custom rule already has 600 IP addresses/ranges, you can create another custom rule and add the new IPs/ranges.
If we add a range (/28) instead of single IP, will it count as 1 entry or it will be counted as a SUM of the whole range?
As per the documentation, it is 600 IP address ranges, so one IP range is considered as 1 entry. And you can add 600 IP ranges in one custom rule.
But you need to make sure that none of the address ranges has overlapping IP addresses and all the ranges have unique IP addresses.
Kindly let us know if the above helps or you need further assistance on this issue.
Please "Accept the answer" if the information helped you. This will help us and others in the community as well.