DPI Tunnel for Linux
Free, simple and serverless solution against censorship for Linux PCs and routers
What is it
DPI Tunnel is a proxy server, that allows you to bypass censorship
It is NOT a VPN and will NOT change your IP
DPI Tunnel uses desync attacks to fool DPI filters
RUN IT AS ROOT
Features
- Bypass many restrictions: blocked or throttled resources
- Create profiles for different ISPs and automatically change them when the connection switches
- Easily autoconfigure for your ISP
- Has HTTP and transparent proxy modes
Configuring
For most of the ISPs, one of the these 2 profiles will be enough
--ca-bundle-path=<path_to_cabundle> --desync-attacks=fake,disorder_fake --split-position=2 --auto-ttl=1-4-10 --min-ttl=3 --doh --doh-server=https://dns.google/dns-query --wsize=1 --wsfactor=6
--ca-bundle-path=<path_to_cabundle> --desync-attacks=fake,disorder_fake --split-position=2 --wrong-seq --doh --doh-server=https://dns.google/dns-query --wsize=1 --wsfactor=6
CA Bundle is a file that contains root and intermediate SSL certificates. Required for DoH and autoconfig to work. You
can get it for example from the curl website
For other ISPs, --auto
will automatically find proper settings
Running
HTTP mode (default)
This mode is good for PC or any other device which will only use the proxy for itself.
Run executable with options either from autoconfig or from one of the suggested profiles. The program will tell IP and
port on which the proxy server is running. 0.0.0.0 IP means any of IPs this machine has.
Set this proxy in browser or system settings
Transparent mode
This mode is good for router which will use the proxy for the entire local network.
Run executable with --mode transparent
and append options either from autoconfig or from one of the suggested
profiles. The program will tell IP and port on which the proxy server is running. 0.0.0.0 IP means any of IPs this
machine has.
If proxy running on router
1. Enable IP forwarding
sysctl -w net.ipv4.ip_forward=1
2. Disable ICMP redirects
sysctl -w net.ipv4.conf.all.send_redirects=0
3. Enter something like the following iptables
rules
iptables -t nat -A PREROUTING -i <iface> -p tcp --dport 80 -j REDIRECT --to-port <proxy_port> iptables -t nat -A PREROUTING -i <iface> -p tcp --dport 443 -j REDIRECT --to-port <proxy_port>
If proxy running on machine in local network (Raspberry PI for example)
1. On router
iptables -t mangle -A PREROUTING -j ACCEPT -p tcp -m multiport --dports 80,443 -s <proxy_machine_ip> iptables -t mangle -A PREROUTING -j MARK --set-mark 3 -p tcp -m multiport --dports 80,443 ip rule add fwmark 3 table 2 ip route add default via <proxy_machine_ip> dev <iface> table 2
2. On proxy machine
- Enable IP forwarding
sysctl -w net.ipv4.ip_forward=1
- Disable ICMP redirects
sysctl -w net.ipv4.conf.all.send_redirects=0
- Enter something like the following
iptables
rules:
iptables -t nat -A PREROUTING -i <iface> -p tcp --dport 80 -j REDIRECT --to-port <proxy_port> iptables -t nat -A PREROUTING -i <iface> -p tcp --dport 443 -j REDIRECT --to-port <proxy_port>
Links
- Telegram chat
- Android Version
- 4PDA
Thanks
- ValdikSS (GoodbyeDPI)
- nomoresat (DPITunnel-cli)
Dependencies
- RawSocket
- cpp-httplib
- dnslib
- libnl
vpn
proxy
privacy
encryption
censorship-circumvention
Free, open-source tool for accessing blocked websites & apps; encrypts traffic between user device and external server.
What is DPI Tunnel?
DPI Tunnel is a free, open-source anti-censorship tool developed by Psiphon that allows users to bypass internet censorship and access websites and apps that may be blocked in their country. It works by establishing an encrypted tunnel between the user’s device and one of Psiphon’s servers located outside of the censoring country.
When a user connects through DPI Tunnel, all of their device’s traffic is securely encrypted and routed through Psiphon’s server before reaching its final destination. This prevents network administrators from analyzing and filtering the user’s traffic via deep packet inspection (DPI) and blocks. Only Psiphon’s server can decrypt the traffic before passing it on to the desired website or app.
This allows users in censored regions to freely access news media, social platforms, communication apps like WhatsApp and Signal, and other sites that their governments attempt to restrict. The tool is designed to be easy to set up and use — users only need to install the app and connect with one click.
DPI Tunnel routes traffic through highly available proxy servers operated by Psiphon that are distributed globally. It incorporates multiple obfuscation techniques to avoid blocks and detection. The tool is free and open-source, available on Windows, Android, and iOS.
DPI Tunnel Features
Features
- Encrypts internet traffic to bypass censorship and access blocked content
- Uses SOCKS5 proxies to route traffic through an external server, hiding contents from network filtering
- Open-source software available free of charge
- Compatible with Windows, Mac, Linux, iOS and Android devices
- Allows access to websites, apps, VoIP services blocked by firewalls and filters
- Circumvents geo-restrictions to access content not available in certain regions
- Supports TCP and UDP traffic for versatility
Pros
Free and open-source
Effective at bypassing internet censorship and restrictions
Easy to set up and use
Works on many platforms and devices
Actively developed and maintained
Cons
Requires an external SOCKS5 proxy server
Proxy servers can monitor traffic
May not work in countries with advanced censorship technology
Requires some technical knowledge to configure
Can be slow if proxy server is far away or overloaded
Official Links
The Best DPI Tunnel Alternatives
Top
Security & Privacy
and
Vpn & Proxy Tools
and other similar apps like DPI Tunnel
Proton VPN
Proton VPN is a virtual private network (VPN) service offered by Proton Technologies AG, the company behind ProtonMail encrypted email. Proton VPN aims to provide online privacy, security and freedom by routing internet traffic through an encrypted tunnel to hide users’ IP addresses and bypass censorship.Some key features of Proton…
PowerTunnel
PowerTunnel is a versatile network tunneling application that provides users with enhanced privacy, security, and accessibility online. It works by encrypting traffic between the user’s device and a remote server, allowing users to bypass firewalls, unblock geo-restricted websites, secure public WiFi connections, and more.Some key features of PowerTunnel include:Encryption -…
Green Tunnel
Green Tunnel is a virtual private network (VPN) service launched in 2018 that focuses on providing secure and private internet access to its users. It uses military-grade encryption and other advanced protocols to protect user data and hide IP addresses.Some key features of Green Tunnel VPN include:Encryption using AES 256-bit…
Что такое DPI?
DPI (Deep Packet Inspection) — технология, позволяющая собирать статистическую информацию из пакетов, проверять их и, конечно же, фильтровать информацию, в зависимости от содержимого пакета. Иногда операторы фильтруют с помощью этой технологии целые протоколы, такие как BitTorrent.
Различают два типа DPI: пассивный и активный. Разница лишь в том, что активный может заблокировать пакет и не дать ему дойти до адресата, а пассивный только лишь отправить фейковый пакет с редиректом или сбросом соединения. Способы обхода обоих схожи.
Как обмануть DPI?
Системы анализа пакетов сконструированы так, чтобы обрабатывать трафик с максимально возможной скоростью, исследуя только часто встречающиеся запросы и пропуская нетипичные, даже если они полностью соответствуют стандарту.
HTTP
Типичный HTTP запрос (такой отправляют все известные браузеры) выглядит следующим образом:
GET /index.php HTTP/1.1
Host: ru.wikipedia.org
User-Agent: Mozilla/5.0 (X11; U; Linux i686; ru; rv:1.9b5) Gecko/2008050509 Firefox/3.0b5
Accept: text/html
Connection: keep-alive
Все заголовки начинаются с большой буквы, далее двоеточие, затем один пробел, значение заголовка и конец строки в виде CRLF (\r\n).
Заглянем в RFC 7230:
Each header field consists of a case-insensitive field name followed
by a colon (":"), optional leading whitespace, the field value, and
optional trailing whitespace.
Согласно нему, заголовки не чувствительны к регистру, а после двоеточия может быть любое число пробелов. Это значит, что сломать DPI можно с помощью изменения «Host:» на «hOsT:». Большинство серверов примет пакет и если заменить символ конца строки с CRLF (\r\n) на LF (\n).
HTTPS
В случае с HTTPS, DPI ищют незашифрованное поле SNI, в котором содержится адрес сайта. Можно было бы изменить поле SNI, но для этого придётся модифицировать системные библиотеки, поэтому для обхода блокировок по HTTPS используется фрагментация пакетов, которая, кстати, может использоваться и для HTTP. Суть в том, что почти все DPI умеют работать только с отдельно взятыми пакетами, а читать всё соединение они не умеют, поэтому достаточно отправить запрос к сайту в виде нескольких TCP пакетов.
DNS
Все предыдущие методы бесполезны, если адрес сайта неверно определился на уровне DNS сервера. Дело в том, что многие операторы перенаправляют все DNS запросы на свой сервер и если сайт заблокирован, отправляют некорректный ответ. Решается использованием протокола DoH.
Методы дурения DPI на android
Для Windows и Linux уже существуют решения вроде GoodbyeDPI и GreenTunnel, но для android до недавнего времени ничего такого не было, поэтому я решил сделать свою программу, и получился DPI Tunnel.
Работает эта штука как локальный HTTP прокси, на который направляет весь трафик системы и модифицирует его с использованием вышеперечисленных способов. Если и они не сработают, то есть поддержка socks5 прокси, который используется только для заблокированных сайтов и не замедляет работу остальных.
Как использовать
Если есть root, то в настройках программы выбрать «Установить DPITunnel прокси глобально» и нажать кнопку на главном экране, если root нет, то нажать кнопку на главном экране и выставить прокси в ручную в настройках Wi-Fi или APN. Адрес прокси: 127.0.0.1, порт тот, что указан в настройках программы.
Известные баги
Из багов можно выделить то, что иногда, если фоновой сервис убила система и он не смог нормально завершится, при повторном старте сервиса он падает через несколько секунд. Решается тем, что выбирается другой порт в настройках программы.
Github: DPITunnel
4PDA: DPITunnel
DPI Tunnel v2 for Android
1.2 GPL-3.0-only
Free, simple and serverless solution against censorship for Android
Download APK (11.4 MB)
Description
Versions
Version
1.2 (3)
Update
Developer
Evgeniy (aka zhenyolka)
Category
Internet
License
GPL-3.0-only
Source code
Code repository
DPI Tunnel is an app, that allows you to bypass censorship
DPI Tunnel uses desync attacks to fool DPI filters
It is NOT VPN and won’t change your IP
Features
* Bypass many restrictions: blocked or throttled resources
* Create profiles for different ISP and automatically change them when switch connection
* Auto start program on device boot
* Easily auto configure for your ISP
Issues & Comments
Submit issue
Old versions
-
DPI Tunnel v2 1.2
APK
Android SDK 21
-
DPI Tunnel v2 1.1
APK
Android SDK 21
-
DPI Tunnel v2 1.0
APK
Android SDK 21
Similar apps
ByeDPI
★3,378
ByeByeDPI
★1,207
PowerTunnel
★1,670
SocksTun
★372
Riseup VPN
★5
Rethink
★1,491
PCAPdroid
★2,669
Ping Tunnel Plugin
★5
NETBRIGHT
★123
InviZible Pro
★1,754
TRENDING SEARCHES
fossify
launcher
vpn
music
Kotatsu
youtube
pdf
keyboard
newpipe
outertune
rimusic
simpmusic
camera
gallery
telegram
music player
seal
osmand
meditation
mull
fennec
file manager
notes
spotube
clock
time
signal
immich
video
wifi
calculator
calendar
vlc
weather
battery
email