shadowsocks/ChinaDNS
FreeProtect yourself against DNS poisoning in China.
FreeFree tier
About shadowsocks/ChinaDNS
ChinaDNS is an open-source DNS proxy tool designed to protect against DNS poisoning in China. It automatically resolves Chinese domain names using local DNS servers and foreign domain names using foreign DNS servers, based on a Chinese IP range file (chnroute.txt). This eliminates the need for manually maintained domain lists, which change frequently. ChinaDNS supports the DNS pointer mutation method (-m option) to bypass IP blocking and can be used alongside VPN software like ShadowVPN. It is available for Linux/Unix, OpenWRT, Tomato, and Windows.
Key Features
Automatically routes Chinese domains to local DNS and foreign domains to foreign DNS
Uses a Chinese IP range file (chnroute.txt) that changes infrequently
Supports DNS pointer mutation method (-m) to bypass IP blocking
Compatible with VPN software like ShadowVPN
Installation guides for Linux/Unix, OpenWRT, Tomato, and Windows
Can be set as upstream DNS server for dnsmasq on OpenWRT
Pros & Cons
Pros
- No need to maintain an ever-changing domain list
- IP range file updates are infrequent, reducing maintenance
- Open source with active community and multiple installation options
- Works with existing VPN solutions to bypass IP blocking
Cons
- Requires manual command-line setup and configuration
- Only designed for DNS poisoning scenarios in China (not general DNS filtering)
- Relies on accurate chnroute.txt file; may not cover all scenarios
Best For
Bypassing DNS poisoning to access foreign websites in ChinaResolving Chinese domain names with accurate CDN resultsCombining with VPN for complete internet freedomUsing as a local DNS resolver for improved network reliability
FAQ
How does ChinaDNS differ from a traditional VPN-based DNS approach?
Traditional VPN sends all DNS queries to a foreign server, causing Chinese websites with CDNs to return bad results. ChinaDNS automatically resolves Chinese domains locally and foreign domains via foreign DNS, ensuring correct results for both.
Does ChinaDNS require a constantly updated domain list?
No. It uses a Chinese IP range file (chnroute.txt) which changes infrequently, eliminating the need for a frequently updated domain list.
Can ChinaDNS be used without a VPN?
To bypass IP blocking, ChinaDNS recommends using VPN software like ShadowVPN alongside it.
What platforms are supported?
ChinaDNS supports Linux/Unix, OpenWRT, Tomato, and Windows (via Python exe).
How do I install ChinaDNS on OpenWRT?
Download the precompiled package for your CPU (ar71xx, brcm63xx, brcm47xx, ramips_24kec) or build from source. Then install with opkg, start the init script, and optionally configure as upstream for dnsmasq.