My own DNS forwarder (Tunlr clone)

I was following some tutorial on how to setup a tunlr clone blindly and couldn’t get things working… put some thought into it and it’s working now (sort of).

The guide I’m following was DIY clone of Netflix Tunlr/Unblock-Us/UnoTelly on cheap US based VPS

Only difference was that I was using sniproxy 0.3.4 instead of 0.1.1. 0.3.6 doesn’t seem to use /etc/sniproxy.conf at all so I didn’t get it working.


I might update this page to include the updated instruction set on a later date.


— Ignore below —

OS: CentOS 6 x86_64

Provider:  shared 0.5GB RAM 1TB @ 1Gbps bandwidth


cd /tmp

#rpm -Uvh epel-release-7-2.noarch.rpm
#rm -rf epel-release-7-2.noarch.rpm
rpm -Uvh epel-release-6-8.noarch.rpm
rm -rf epel-release-6-8.noarch.rpm

yum update -y yum install openssl vim git wget curl bind-utils telnet -y 
yum groupinstall "Development Tools" -y 
yum install rpmbuild autoconf automake curl libev libev-devel pcre pcre-devel perl udns-devel -y 
yum install bind bind-chroot -y 

cd /var/named/chroot/etc/ 
cp /etc/named.* . 
vi named.conf 
#edit named.conf 
vi /var/named/chroot/etc/named/db.override 
#edit db.override 
vi /var/named/chroot/etc/zones.override 
#edit zones.override 
chown -hR named:named /var/named/ 
rndc-confgen -a -r /dev/urandom -t /var/named/chroot 
chkconfig named on 
service named start 

cd /opt 
#latest version doesn't seem to use sniproxy.conf
#git clone 
#get 0.3.4 instead
cd ./sniproxy 
./ && ./configure && make dist 
rpmbuild --define "_sourcedir `pwd`" -ba --nodeps redhat/sniproxy.spec 
yum install /root/rpmbuild/RPMS/x86_64/sniproxy-0.* -y 

#version 0.3.4 install only
vi /etc/sniproxy.conf

#### sniproxy.conf #####
# grep '^[^#]' /etc/sniproxy.conf
user daemon
pidfile /var/tmp/
listener 107.155.x.y 80 {
        proto http
listener 107.155.x.y 443 {
        proto tls
table {
        netflix\.com *
	speedtest\.net *
#### end sniproxy.conf ####

cp ./redhat/sniproxy.init /etc/init.d/sniproxy 
chmod +x /etc/init.d/sniproxy 
chkconfig sniproxy on 
service sniproxy start

3 Replies to “My own DNS forwarder (Tunlr clone)”

  1. First of all, must say that its a great tutorial.
    I have one question though

    “Is it possible to stream everything through SNI Proxy” e.g. youtube

    1. My assumption would be you’d just select this instead of (or whatever you set as your default when configuring this), you might need to select the domains too but that’s all I can think of. It’s not the best idea though, at that point you might as well setup a SOCKS proxy or a transparent one on the router side.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.