Search notes:

Perl module Net::WhoisNG

#!/usr/bin/perl
#
#   http://stackoverflow.com/a/11899899/180275
#
use warnings;
use strict;

use Net::WhoisNG;

my $addr = shift or die;

# my $whois = Net::WhoisNG->new($addr) or die;

$whois -> lookUp() or die;

print $whois->getExpirationDate, "\n";

foreach my $type (qw(admin tech registrant bill)) {

  if (my $contact=$whois->getPerson($type)) {

      print "$type\n";
      my $email = $contact->getEmail();

      if ($email and $email =~ /\S/) {
          print "$email\n";
      } else {
          my $unparsed = join(' ', @{$contact->getCredentials()});
        # Use an regexp to extract e-mail from freeform text here, you can even pick ready one somewhere here on SO
          print "$unparsed\n";
      }
      print "----\n\n";
  }

}
Github repository PerlModules, path: /Net/WhoisNG/script.pl

See also

Net::Whois::Parser
Perl modules

Index

Fatal error: Uncaught PDOException: SQLSTATE[HY000]: General error: 8 attempt to write a readonly database in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php:78 Stack trace: #0 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(78): PDOStatement->execute(Array) #1 /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php(30): insert_webrequest_('/notes/developm...', 1741107277, '3.149.235.190', 'Mozilla/5.0 App...', NULL) #2 /home/httpd/vhosts/renenyffenegger.ch/httpsdocs/notes/development/languages/Perl/modules/Net/WhoisNG/index(75): insert_webrequest() #3 {main} thrown in /home/httpd/vhosts/renenyffenegger.ch/php/web-request-database.php on line 78