A powerful DNS toolkit for python

nslookup is a network administration command-line tool available for many computer operating systems for querying the Domain Name System (DNS) to obtain domain name or IP address mapping or for any other specific DNS record. – Wikipedia

DNS record types
A,AAAA,AFSDB,APL,CAA,CDNSKEY,CDS,CERT,CNAME,DHCID,DLV,
DNAME,DNSKEY,DS,HIP,IPSECKEY,KEY,KX,LOC,MX,NAPTR,NS,
NSEC,NSEC3,NSEC3PARAM,PTR,RRSIG,RP,SIG,SOA,SRB,SSHFP,
TA,TKEY,TLSA,TSIG,TXT,*,AXFR,IXFR,OPT – Wikipedia

dnspython is a DNS toolkit for Python. It supports almost all record types. It can be used for queries, zone transfers, and dynamic updates. It supports TSIG authenticated messages and EDNS0.

dnspython provides both high and low level access to DNS. The high level classes perform queries for data of a given name, type, and class, and return an answer set. The low level classes allow direct manipulation of DNS zones, messages, names, and records.

Download
Download from Github.

git clone https://github.com/rthalley/dnspython

Installation

pip install dnspython

or
Download the source file, unzip it and run:

sudo python setup.py install

Documentation
http://www.dnspython.org/docs/1.13.0/

Categories: Python Tags: , , ,
%d bloggers like this: