I'm actually not 100% sure what my issue is. Carp::Always gives me this trace:
Undefined subroutine &Net::Whois::ARIN::Network::OrgName called at /ho +me/me /perl5/perlbrew/perls/perl-5.16.2/lib/site_perl/5.16.2/Net/Whois/ARIN/ +Network.pm line 176. Net::Whois::ARIN::Network::AUTOLOAD('Net::Whois::ARIN::Network +=HASH(0x7f fe67857180)') called at lib/ProbeS/Misc.pm line 50 ProbeS::Misc::rev_ip(96.255.24.1) called at lib/ProbeS/NetHist +.pm line 83 ProbeS::NetHist::nethist('HASH(0x7ffe5bfd9fa8)', 'HASH(0x7ffe6 +41f4e78 )', 0) called at /home/me/perl5/perlbrew/perls/perl-5.16.2/lib/site_pe +rl/5. 16.2/Net/Whois/ARIN/Network.pm line 176. Net::Whois::ARIN::Network::AUTOLOAD('Net::Whois::ARIN::Network +=HASH(0x7f fe67857180)') called at lib/ProbeS/Misc.pm line 50 ProbeS::Misc::rev_ip(96.255.24.1) called at lib/ProbeS/NetHist +.pm line 83 ProbeS::NetHist::nethist('HASH(0x7ffe5bfd9fa8)', 'HASH(0x7ffe6 +41f4e78 )', 0) called at ./probes line 285

My test (that works) is as follows:
#!/usr/bin/env perl use strict; use warnings; BEGIN { push @INC, './lib'; } use T; foreach my $i (qw/8.8.8.8 4.2.2.2 4.2.2.1 8.8.4.4/) { print rev_ip($i) . "\n"; }
and T.pm:
package T; BEGIN { require Exporter; our $VERSION = 1.1; our @ISA = 'Exporter'; our @EXPORT = qw(rev_ip); } use strict; use warnings; use Data::Dumper; use Net::DNS::Resolver; use Net::Whois::ARIN; my $dns = Net::DNS::Resolver->new; my $w = Net::Whois::ARIN->new; sub rev_ip { my ($ip) = @_; my $org = ''; my $rev = ''; $org = join ", ", map { $_->OrgName } $w->network($ip); my $packet = $dns->search($ip); $rev = join ', ', map { $_->rdatastr } grep { $_->type eq 'PTR' } $p +acket->answer if $packet; return "[$ip] [$org] [$rev]"; }

In reply to Net::Whois::ARIN autoload by ag4ve

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.