All Projects → henices → Tcp Dns Proxy

henices / Tcp Dns Proxy

A TCP dns proxy which can get the RIGHT ip address

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Tcp Dns Proxy

Vedetta
OpenBSD Router Boilerplate
Stars: ✭ 260 (-67.25%)
Mutual labels:  dns-server
Gdnsd
Authoritative DNS Server --
Stars: ✭ 370 (-53.4%)
Mutual labels:  dns-server
Whonow
A "malicious" DNS server for executing DNS Rebinding attacks on the fly (public instance running on rebind.network:53)
Stars: ✭ 533 (-32.87%)
Mutual labels:  dns-server
Netflix Proxy
Smart DNS proxy to watch Netflix
Stars: ✭ 3,220 (+305.54%)
Mutual labels:  dns-server
Gasper
Your Cloud in a Binary
Stars: ✭ 331 (-58.31%)
Mutual labels:  dns-server
Shaman
Small, lightweight, api-driven dns server.
Stars: ✭ 426 (-46.35%)
Mutual labels:  dns-server
MicroDNSSrv
A micro DNS server for MicroPython to simply respond to A queries on multi-domains with or without wildcards (used on Pycom modules & ESP32)
Stars: ✭ 43 (-94.58%)
Mutual labels:  dns-server
Sdns
Privacy important, fast, recursive dns resolver server with dnssec support
Stars: ✭ 658 (-17.13%)
Mutual labels:  dns-server
Smartdns
A local DNS server to obtain the fastest website IP for the best Internet experience, 一个本地DNS服务器,获取最快的网站IP,获得最佳上网体验。
Stars: ✭ 4,333 (+445.72%)
Mutual labels:  dns-server
Blocky
Fast and lightweight DNS proxy as ad-blocker for local network with many features
Stars: ✭ 523 (-34.13%)
Mutual labels:  dns-server
Surging
Surging is a micro-service engine that provides a lightweight, high-performance, modular RPC request pipeline. The service engine supports http, TCP, WS,Grpc, Thrift,Mqtt, UDP, and DNS protocols. It uses ZooKeeper and Consul as a registry, and integrates it. Hash, random, polling, Fair Polling as a load balancing algorithm, built-in service gove…
Stars: ✭ 3,088 (+288.92%)
Mutual labels:  dns-server
Your Dns
A docker-compose file to provide a secure adblocking DNS server
Stars: ✭ 333 (-58.06%)
Mutual labels:  dns-server
Dns Proxy Server
Solve your DNS hosts from your docker containers, then from your local configuration, then from internet
Stars: ✭ 480 (-39.55%)
Mutual labels:  dns-server
Roguesploit
Powerfull Wi-Fi trap!
Stars: ✭ 262 (-67%)
Mutual labels:  dns-server
Dnsserver
Technitium DNS Server
Stars: ✭ 603 (-24.06%)
Mutual labels:  dns-server
v6dns
A DNS Server which lets IPv4-prioritized devices to use IPv6 first, or lets IPv6-prioritized devices to use IPv4 first.
Stars: ✭ 16 (-97.98%)
Mutual labels:  dns-server
Dnsclient.net
DnsClient.NET is a simple yet very powerful and high performant open source library for the .NET Framework to do DNS lookups
Stars: ✭ 400 (-49.62%)
Mutual labels:  dns-server
Hestiacp
Hestia Control Panel | A lightweight and powerful control panel for the modern web.
Stars: ✭ 764 (-3.78%)
Mutual labels:  dns-server
Rubydns
A DSL for building fun, high-performance DNS servers.
Stars: ✭ 652 (-17.88%)
Mutual labels:  dns-server
Dnsmasq sniproxy install
One-click Install and Configure Dnsmasq and Sniproxy for CentOS/Debian/Ubuntu
Stars: ✭ 515 (-35.14%)
Mutual labels:  dns-server

Build Status

How to use this python script ?

  1. change your dns server to 127.0.0.1
$ vi /etc/resolve.conf  
nameserver 127.0.0.1
  1. restart the network
$ sudo /etc/init.d/networking restart
  1. run the script
$ sudo python tcpdns.py -f tcpdns.json.example
  1. stop the daemon process
$ sudo python tcpdns.py -s

Commandline

usage: tcpdns.py [-h] -f CONFIG_JSON [-d]

TCP DNS Proxy

optional arguments:
  -h, --help      show this help message and exit
  -f CONFIG_JSON  Json config file
  -d              Print debug message
  -s              Stop tcp dns proxy daemon

Configuration file

{
    "socket_timeout": 20,
    "host": "0.0.0.0",
    "port": 53,
    "tcp_dns_server": ["8.8.8.8:53",
                       "8.8.4.4:53",
                       "156.154.70.1:53",
                       "156.154.71.1:53",
                       "208.67.222.222:53",
                       "208.67.220.220:53",
                       "209.244.0.3:53"],
    "udp_dns_server": ["208.67.222.222:5353"],
    "enable_server_switch": true,
    "speed_test": true,
    "enable_lru_cache": true,
    "lru_cache_size"  : 500,
    "udp_mode"        : false,
    "daemon_process"  : false,
    "internal_dns_server": ["192.168.1.1:53"],
    "internal_domain": ["*intra*"],
    "private_host"    : {"*google.com": "203.117.34.162"}
}
  • enable_server_switch: switch dns servers if network is slow
  • speed_test : test dns server speed on startup
  • enable_lru_cache : use lru cache to store dns server responses
  • udp_mode : use udp dns procotol, default is tcp dns protocol
  • daemon_process : daemon process on *nix platform
  • internal_dns_server : internal dns server on internal network
  • internal_domain : internal domains which use internal dns server to get ip address
  • private_host : like /etc/hosts on *nix platform

Dependencies

libraries

python moudules

INSTALL

Super-quick installation

Linux system

  chmod +x ./install.sh
  ./install.sh

Windows system

Use tcpdns.exe in win directory.

Manual Installation

Ubuntu or Debian installation guide

  1. Use the following commands to install python modules

      sudo apt-get install libevent-dev
      sudo apt-get install python-pip
      sudo pip install gevent
      sudo pip install python-daemon
    
  2. Pull the submodule source code.

      cd Tcp-DNS-proxy
      git submodule update --init --recursive
    

Windows installation guide

In order to build gevent library you should install Visual Studio, although tcpdns.py can run perfectly without python gevent. If you cannot run "C:\Python27\Scripts\pip.exe" in the CMD, you can try "C:\Python27\python.exe -m pip".

  1. Pull the submodule source code.

      cd Tcp-DNS-proxy
      git submodule update --init --recursive
    
  2. install python 2.7.9

  3. Install pip.exe

    Download get-pip.py from get-pip.py, execute the following commands:

    python get-pip.py
    
  4. install greenlet

    C:\Python27\Scripts\pip.exe install greenlet
    
  5. install Microsoft Visual C++ Compiler for Python 2.7

Download link

  1. Install python gevent

    C:\Python27\Scripts\pip.exe install gevent
    
  2. install pyinstaller

    C:\Python27\Scripts\pip.exe install pyinstaller
    
  3. execute toexe.bat

LICENSE

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].