AUTHOR : Vasilis Manthelas OFFICIAL-WEBSITE
Python module for capturing dns traffic
- GITHUB
$ git clone https://github.com/j0ck3r2004/dnsCapture/ $ cd dnsCapture $ python3 setup.py bdist_wheel $ python3 -m pip install dist/*.whl
- PIP
$ pip3 install dnsCapture
- python
VERSION RUNS - scapy
- windows
python -m pip scapy
- linux
pip3 install scapy
- dnsCapture folder musst be in the same directory as your program
|DIRECTORY-| |----------| |program.py| |dnsCapture|
`DNS_TRAFFIC(IFACE,type) | IFACE(string) = your interface, type(1byte) = request(0) or response(1) `
-
CAPTURE DNS REQUESTS LIVE
import dnsCapture.dnsCapture as dnsCapture dns=dnsCapture.DNS_TRAFFIC() while True: captured=dns.stream('interface',0) print(captured)
[RETURNING]
NAME VALUE MEANING src 'x.x.x.x' localhost dst 'x.x.x.x' DNS url 'https://X.X' requested url -
CAPTURE DNS RESPONSES LIVE
import dnsCapture.dnsCapture as dnsCapture dns=dnsCapture.DNS_TRAFFIC() while True: captured=dns.stream('interface',1) print(captured)
[RETURNING]
NAME VALUE MEANING src 'x.x.x.x' DNS dst 'x.x.x.x' localhost url 'https://X.X' requested url ip 'x.x.x.x' requested url's ip -
PRINT HELP
import dnsCapture.dnsCapture as dnsCapture print(dnsCapture.help())
-
PRINT CREDITS
import dnsCapture.dnsCapture as dnsCapture print(dnsCapture.credits())