Skip to content

DNS Hole is a network-level advertisement and Internet tracker blocking tool which acts as a DNS sinkhole.

License

Notifications You must be signed in to change notification settings

gdsoumya/dns_hole

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DNS Hole

License: MIT made with python tweet button

DNS Hole is a network-level advertisement and Internet tracker blocking tool which acts as a DNS sinkhole. It comes with a tracker and advertisement block list that can be customized according to user preferences and requirements.

DNS Hole Cli

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

DNS Hole requires Python (> Python 3.6) .

Getting the project.

$ git clone https://github.com/gdsoumya/dns_hole.git
or 
Download and extract the Zip-File

Installing Dependencies

The Project has a few dependencies which can be installed by running.

$ pip install -r dependencies.txt 

Starting DNS Hole

To start blocking ads and trackers run

$ python dns_hole.py

Options

  • Aggressive Mode : Aggressively blocks any link which contains the keyword "AD". Use with CAUTION, links like googleadservices.com as well as links like addition.com will be blocked.

Finally a DNS Server will be initialized at 0.0.0.0:53 for use.

Errors

Possible Errors :

  1. Run As Root : On linux based systems the script needs to be executed as root, on windows admin permissions will be requested.
  2. Port 53 is already in use/Socket Error : Other processes or services are using the required port(53), kill or close them before executing the script.

Using DNS Hole

To use DNS Hole you can choose one of the following options:

  1. Setup DNS Hole on the Hotspot/Router.
  2. Set the DNS address in your router settings to point to the DNS Hole system.
  3. Setup network settings on specific devices to point their dns to the DNS Hole system.

Changing Block List

To change/update the block list just add or remove the necessary urls in the BlockList.txt file.

Working Demo

DNS Hole Demo

Packages Used

  • dnslib : A library to encode/decode DNS wire-format packets.

Author

  • Soumya Ghosh Dastidar

Contributting

Any contribution/suggestions are welcomed.

About

DNS Hole is a network-level advertisement and Internet tracker blocking tool which acts as a DNS sinkhole.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages