I have a list of IPs in MAXCDN_ARRAY to be used as whitelist. I want to check if a specific IP address is in range in this array. How can I structure the code so that it can compare all IPs in the array and say the specific IP in in range of this list or not?
GrepCIDR
You can use grepcidr to check if an IP address is in a list of CIDR networks.