A
Adam Funk
I'm trying to write some Perl code to check an IP addresses against a list
of strings containing IP address, partial IP addresses ending in ".",
net/mask pairs and net/masklength pairs.
In other words, I'd like ip_found("192.168.2.3") to return true if the test
list contains any of the following:
192.168.2.3
192.168.
192.168.2.0/255.255.255.0
192.168.2.0/24
I'm sure someone else has done this already -- any good code to recycle?
Thanks,
Adam
of strings containing IP address, partial IP addresses ending in ".",
net/mask pairs and net/masklength pairs.
In other words, I'd like ip_found("192.168.2.3") to return true if the test
list contains any of the following:
192.168.2.3
192.168.
192.168.2.0/255.255.255.0
192.168.2.0/24
I'm sure someone else has done this already -- any good code to recycle?
Thanks,
Adam