Skip to content
Back to the collection

Automated Symbolic Verification of Telegram's MTProto 2.0

Marino Miculan, Nicola Vitacolonna

2020 · arXiv

Read the paper
HN score
0
Mentions
7
Readers
5
Months
4
What’s in a score?

From the abstract

MTProto 2.0 is a suite of cryptographic protocols for instant messaging at the core of the popular Telegram messenger application. In this paper we analyse MTProto 2.0 using the symbolic verifier ProVerif. We provide fully automated proofs of the soundness of MTProto 2.0's authentication, normal chat, end-to-end encrypted chat, and rekeying mechanisms with respect to several security properties, including authentication, integrity, secrecy and perfect forward secrecy; at the same time, we discover that the rekeying protocol is vulnerable to an unknown key-share (UKS) attack. We proceed in an incremental way: each protocol is examined in isolation, relying only on the guarantees provided by the previous ones and the robustness of the basic cryptographic primitives. Our research proves the formal correctness of MTProto 2.0 w.r.t. most relevant security properties, and it can serve as a reference for implementation and analysis of clients and servers.

Metadata: arXiv. Abstracts retain their original authors’ rights.

In the conversation

Original HN comments, with labels from simple text rules. A label describes the whole comment and may miss context or irony. Read the discussion to make up your own mind. About the labels

7 selected excerpts · 7 total mentions

gloosx
Neutral mention · rule
That's a popular lie, Telegram uses the MTProto 2.0 Cloud algorithm for non-secret chats, which is audited and verified by multiple independent parties. For example WhatsApp claims it uses EE2E encrypted chats, how ever these claims are unverified and not audited. Also their chief executives are not in jail, coincidentally. You can consult these links if you want to read more about it: https://core.telegram.org/mtproto/AJiEAwIYFoAsBGJBjZwYoQIwFM... https://arxiv.org/pdf/2012.03141 https://github.com/miculan/telegram-mtproto2-verification
NayamAmarshe
Neutral mention · rule
> They are stored in plaintext on telegram servers FYI, this is a totally misleading and false claim. Telegram uses the MTProto 2.0 Cloud algorithm for non-secret chats[1][2]. In fact, it uses a split-key encryption system and the servers are all stored in multiple jurisdictions. So even Telegram employees can't decrypt the chats, because you'd need to compromise all the servers at the same time. Telegram's algorithm has been independently audited multiple times. Compared to other apps like WhatsApp with claims of E2EE and no body of verification and validation.[3] [1]: https://core.telegram.org/mtproto#general-description [2]: https://core.telegram.org/mtproto/AJiEAwIYFoAsBGJBjZwYoQIwFM... [3]: https://arxiv.org/pdf/2012.03141
robryk
Neutral mention · rule
> The algorithm is public. It is a straightforward application of well known primitives. It is hardly proprietary. Note that its predecessor, was very much not that (e.g. https://words.filippo.io/dispatches/telegram-ecdh/ was a vulnerability in it, and it stuck to some weird choices of crypto primitives/key sizes for a pretty long time). This colors my expectations about the current version slightly. I personally know nothing about the current protocol used (mtproto 2.0) and a few minutes of googling surfaced https://eprint.iacr.org/2022/595.pdf, https://eprint.iacr.org/2023/469 and https://arxiv.org/abs/2012.03141, which I'd need to read in reasonable amount of detail to have an opinion on mtproto 2.0.
lloeki
Neutral mention · rule
> Telegram holds the keys to decrypt the messages and that's all you need to know. That's an entirely different problem than TFA (an attacker accessing and being able to impersonate an account by subverting a third party 2FA middleman), which Telegram guards against as as soon as you have one device enrolled the code is sent over Telegram, not SMS. > It's why you are able to just login to your Telegram account on another device and magically get all of your message history. Being able to log in and get your history to sync is not a telltale sign that history is not encrypted and thus visible server side. It could be stored encrypted and upon login decrypted locally (how…
Read the full comment
to achieve that is left as an exercise to the reader, see 1password, restic, borg, and many others that store with zero trust yet are accessible by multiple devices, or even multiple parties) (side note: claims that multi-device messaging can't be done because E2E are incorrect, e.g iMessage does it, by having each message encrypted multiple times, once for each device of the recipient account) > So while the tech might be solid, the keys are still out there. They can be leaked. They can be subpoenaed IIRC it was advertised that Telegram keys (presumably for data at rest) are stored split upon two (or more) different servers residing in different jurisdictions so that subpoenas would only get at most half of it or require international cooperation. But then if you enter that ground, Telegram just as much as Signal could be court-pressured to produce a client that wiretaps data right where it's decrypted and phone home, so E2E only saves you if you audit every client version that this does not happen. As always in matters of security, first step is to define your threat model, and who you want to secure against, as there's no such thing as perfect security. > No analysis needed. I would definitely like to see one done by an unbiased party, because everything I can find are blanket gut-feeling statements without reference. EDIT: just found this, which is a bit light but still something: https://restoreprivacy.com/secure-encrypted-messaging-apps/t... and this: https://arxiv.org/pdf/2012.03141v1.pdf
j-james
Neutral mention · rule
Each of these have fairly different use cases. WhatsApp is bad. They are owned by a data collection company notorious for gross privacy violations. Both the client apps and the server are completely closed source, which means either could be spying on you without any way to know. They do claim to implement the secure Signal Protocol, but how do you verify end to end encryption without seeing source code, anyway? Telegram is a perfectly adequate choice. The user experience is similar to WhatsApp. It does practice some dark patterns - end to end encryption is only available in "secret chats" and calls, which means all other messages you send are readable by anyone with a…
Read the full comment
warrant - and has had some high-profile exploits over the years, but the current iteration of its cryptographic protocol has been proved secure [1] (disclaimer: the paper claiming so came out within the last month, and I haven't found any discussion or review). All of the client apps are open source. The server is not, but if the clients are properly encrypting messages, that shouldn't be a security concern (To my knowledge. I am not a cryptographer). Discord is community-oriented. It's primarily based around "guilds" (commonly referred to as servers) that function similar to Slack workspaces. A robust role-based permission systems has made it pretty much the de facto standard for large communities wanting a real-time discussion platform (think subreddits, Discourse forums, etc). They have some top-of-the-line engineers who sometimes publish cool blog posts about their ridiculously performant clients [2]. Nonetheless, nothing is encrypted, they aren't open-source, and they have an unclear monetization model [3]. Signal is designed, intentionally or not, as a SMS replacement. It's build around one on one and small group messages. Their encryption is strong, independently verified, and enabled by default (Signal falls back to SMS for others who don't use it). Think iMessage, but open-source and secure. You'll see HN complain about its UI from time to time, but really, it's quite good. It's also extremely easy to convince friends and family to switch to. Matrix aims to be to real time chat what email is for asynchronous communication. Rather than a service, it's a standard, which means you'll see swaths of clients strewn about GitHub and other websites, the most feature complete of which is Element [4]. In practice (or for the time being), Matrix is just better IRC. VoIP and video calls are somewhat hodge-poged into the spec, but do work well, and encryption by default has been rolling out over the past year. Direct messaging, group chats, and communities are also all supported, although the latter suffers from the IRC-like limitation of only one "channel" per server. I know nothing about Threema or Viber, sorry. [1]: https://arxiv.org/abs/2012.03141 [2]: https://blog.discord.com/why-discord-is-switching-from-go-to... [3]: https://cadence.moe/blog/2020-06-06-why-you-shouldnt-trust-d... [4]: https://element.io/
j-james
Neutral mention · rule
Telegram's protocol itself isn't necessarily a weakness - recently, a paper was published claiming to have proved the MTProto 2.0 protocol correct. Perhaps because of how recent this was, it doesn't seem to have garnered any discussion or review anywhere. https://arxiv.org/abs/2012.03141

Keep following the thread.

More in Security & cryptography

More from the same topics.

2014arXiv

Explaining and Harnessing Adversarial Examples

Ian J. Goodfellow, Jonathon Shlens, Christian Szegedy

Several machine learning models, including neural networks, consistently misclassify adversarial examples---inputs formed by applying small but intentionally worst-case perturbations to examples from the dataset, such that the perturbed input results in the model outputting an incorrect answer with high confidence.

1.5HN score