.\" Automatically generated by Pod::Man 4.07 (Pod::Simple 3.32) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .if !\nF .nr F 0 .if \nF>0 \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} .\} .\" ======================================================================== .\" .IX Title "IP 3pm" .TH IP 3pm "2017-01-05" "perl v5.24.1" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Net::Whois::IP \- Perl extension for looking up the whois information for ip addresses .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 1 \& use Net::Whois::IP qw(whoisip_query); \& \& my $ip = "192.168.1.1"; \&#Response will be a reference to a hash containing all information \&#provided by the whois registrar \&#The array_of_responses is a reference to an array containing references \&#to hashes containing each level of query done. For example, \&#many records have to be searched several times to \&#get to the correct information, this array contains the responses \&#from each level \& my ($response,$array_of_responses) = whoisip_query($ip,$optional_multiple_flag,$optional_raw_flag,$option_array_of_search_options); \&#if $optional_multiple_flag is not null, all possible responses for a give record will be returned \&#for example, normally only the last instance of Tech phone will be give if record \&#contains more than one, however, setting this flag to a not null will return both is an array. \&#The other consequence, is that all records returned become references to an array and must be \&#dereferenced to utilize \&#if $optional_raw_flag is not null, response will be a reference to an array containing the raw \&#response from the registrar instead of a reference to a hash. \&#If $option_array_of_search_options is not null, the first two entries will be used to replace \&#TechPhone and OrgTechPhone is the search method. This is fairly dangerous, and can \&#cause the module not to work at all if set incorrectly .Ve .PP #Normal unwrap of \f(CW$response\fR ($optional_multiple_flag not set) my \f(CW$response\fR = whoisip_query($ip); foreach (sort keys(%{$response}) ) { print \*(L"$_ \f(CW$response\fR\->{$_} \en\*(R"; } .PP #$optional_multiple_flag set to a value my \f(CW$response\fR = whoisip_query( \f(CW$ip\fR,\*(L"true\*(R"); foreach ( sort keys %$response ){ print \*(L"$_ is\en\*(R"; foreach ( @{ \f(CW$response\fR\->{ \f(CW$_\fR } } ) { print \*(L" \f(CW$_\fR\en\*(R"; } } .PP #$optional_raw_flag set to a value my \f(CW$response\fR = whoisip_query( \f(CW$ip\fR,"\*(L",\*(R"true"); foreach (@{$response}) { print \f(CW$_\fR; } .PP #$optonal_array_of_search_options set but not \f(CW$optional_multiple_flag\fR or \f(CW$optional_raw_flag\fR my \f(CW$search_options\fR = [\*(L"NetName\*(R",\*(L"OrgName\*(R"]; my \f(CW$response\fR = whois_query($ip,"\*(L",\*(R"\*(L",$search_options); foreach (sort keys(%{$response}) ) { print \*(R"$_ \f(CW$response\fR\->{$_} \en"; } .SH "DESCRIPTION" .IX Header "DESCRIPTION" Perl module to allow whois lookup of ip addresses. This module should recursively query the various whois providers until it gets the more detailed information including either TechPhone or OrgTechPhone by default; however, this is overrideable. .SH "AUTHOR" .IX Header "AUTHOR" Ben Schmitz \*(-- ben@foink.com .PP Thanks to Orbitz for allowing the community access to this work .PP Please email me any suggestions, complaints, etc. .SH "SEE ALSO" .IX Header "SEE ALSO" \&\fIperl\fR\|(1). Net::Whois