I don't want garbage config to munge to "" to 0 to 0.0.0.0 resulting in a worst case in passwords being advertised all interfaces. Probably re-inventing the wheel but...
Probably:
http://search.cpan.org/~luismunoz/NetAddr-IP-3.24/IP.pm http://search.cpan.org/~manu/Net-IP-1.21/IP.pm http://search.cpan.org/~neely/Data-Validate-IP-0.03/lib/Data/Validate/IP.pm
(I think that last one is what you are really looking for).
Also see Chapter 5 of "Mastering Regular Expressions" for a much more compact regex which will match legal IP addresses:
http://regex.info/
as well as this excellent tool for debugging regex's
http://www.weitz.de/regex-coach/
HTH
John
