Simplify ip_internal function with Perl