Skip to content

Instantly share code, notes, and snippets.

@arcrek
arcrek / telegram-mtproxy.md
Created May 26, 2025 12:36 — forked from rameerez/telegram-mtproxy.md
Telegram Proxy How-To: complete and up-to-date MTProxy tutorial

How to set up a Telegram Proxy (MTProxy)

This tutorial will teach you how to set up a Telegram MTProxy on an Ubuntu 22.04 sever using AWS Lightsail, although you can use any other Linux distribution and cloud provider.

Using a Telegram proxy is a safe, easy and effective way of overcoming Telegram bans. It's useful, for example, to keep using Telegram under tyrannical regimes, or to circumvent judges' decisions to block Telegram.

Telegram proxies are a built-in feature in all Telegram apps (both mobile and desktop). It allows Telegram users to connect to a proxy in just one or two clicks / taps.

Telegram proxies are safe: Telegram sends messages using their own MTProto secure protocol, and the proxy can only see encrypted traffic – there's no way for a proxy to decrypt the traffic and read the messages. The proxy does not even know which Telegram users are using the proxy, all the proxy sees is just a list of IPs.

@arcrek
arcrek / cloudflare_waf_rule.txt
Created August 13, 2024 07:12 — forked from henryonsoftware/cloudflare_waf_rule.txt
cloudflare_waf_rule.txt
(cf.threat_score gt 15) or
(http.user_agent eq "") or
(lower(http.user_agent) contains "crawler" and not http.user_agent contains "ia_archiver") or
(lower(http.user_agent) contains "spider") or
(http.user_agent contains "AhrefsBot/") or
(http.user_agent contains "baidu.com") or
(http.user_agent contains "biggo.com") or
(http.user_agent contains "/bin/bash") or
(http.user_agent contains "DnyzBot/") or
(http.user_agent contains "DotBot/") or