Skip to content
Crypto Write-up Advanced

Analysing and Exploiting the Mantin Biases in RC4

The paper re-analyses the Mantin biases in the RC4 stream cipher and finds the original analysis was wrong in some cases, with the biases sometimes absent and sometimes stronger than predicted. It then builds a plaintext recovery attack that targets two unknown bytes near known plaintext, and extends it with dynamic programming to recover longer plaintexts such as cookies and passwords protected by RC4 in TLS.

eprint.iacr.org

Published on eprint.iacr.org

We explore the use of the Mantin biases (Mantin, Eurocrypt 2005) to recover plaintexts from RC4-encrypted traffic. We provide a more fine-grained analysis of these biases than in Mantin's original work.

The author, on eprint.iacr.org

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the RC4 keystream contains statistical biases (the Mantin biases) that leak information about plaintext bytes, and the original model of these biases was inaccurate.

Impact

An attacker who collects very large numbers of RC4-encrypted ciphertexts could recover short plaintexts such as session cookies or passwords, with the paper reporting an 80% success rate for 16-byte plaintexts using 2^31 ciphertexts.

What the attacker needed

Large volume of RC4 ciphertexts; known plaintext near the target bytes; RC4 used in TLS

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

RC4 is an old way of encrypting data that scrambles it with a repeating keystream. Researchers found that this keystream is not perfectly random and leaks small statistical hints about the original data. This paper sharpens those hints and shows how, with a huge number of captured encrypted messages, an attacker can guess back parts of the secret plaintext.

What is Crypto?

Encryption, signatures, randomness or certificate checks that do not protect what they claim to.

Similar reports

View all

Same bug class and techniques, clearest first.

Cryptographic weaknesses

The lesson behind this report.

Encryption, signatures, randomness or certificate checks that do not protect what they claim to.