• • • • $ nslookup -querytype=mx pluralsight.com $ nslookup server 127.0.0.1 set type=mx pluralsight.com ……… set debug web.theurbanpenguin.com $ dig pluralsight.com -t mx $ dig pluralsight.com +short -t mx $ host www.pluralsight.com # Returns A Record $ host 8.8.8.8 # Returns PTR Record #!/usr/bin/perl use strict; use warnings; use Net::DNS::Resolver; my $hostname; print(“Enter a hostname: “); chomp($hostname = ); my $resolver = Net::DNS::Resolver->new( nameservers => [qw(8.8.8.8)], ); my $query = $resolver->search($hostname); if ($query) { foreach my $record ($query->answer) { next unless $record->type eq "A"; print(“Answer: " $record->address "\n"); } } $ sudo apt-get install -y python3-dnspython #!/usr/bin/python3 import dns.resolver resolver = dns.resolver.Resolver() answers = resolver.query("docker.theurbanpenguin.com","A") for answer in answers: print(answer) • • • • • • ... strict; use warnings; use Net: :DNS: :Resolver; my $hostname; print(“Enter a hostname: “); chomp($hostname = ); my $resolver = Net: :DNS: :Resolver->new( nameservers => [qw(8.8.8.8)], ); my... " $record->address " "); } } $ sudo apt-get install -y python3-dnspython #!/usr/bin/python3 import dns. resolver resolver = dns. resolver.Resolver() answers = resolver.query("docker.theurbanpenguin.com","A")...• • • • $ nslookup -querytype=mx pluralsight.com $ nslookup server 127 .0.0.1 set type=mx pluralsight.com ……… set debug web.theurbanpenguin.com $ dig pluralsight.com