Skip to content

Stream Cipher

Definition

A symmetric cipher that produces a pseudo-random keystream which is XORed bit-by-bit or byte-by-byte with the plaintext. RC4 (legacy), ChaCha20 (current). Stream ciphers can also be built from block ciphers via CTR mode.

Cipher type
Symmetric
Mechanism
XOR with pseudo-random keystream
Legacy example
RC4
Current example
ChaCha20

Common questions

Why is RC4 considered legacy rather than current practice?+

RC4's keystream has known statistical biases that let attackers recover plaintext from enough captured traffic, which is why modern protocols moved to ciphers like ChaCha20 or AES in an authenticated mode instead.

How can a stream cipher be built out of a block cipher?+

Running a block cipher in counter mode (CTR) turns it into a keystream generator: the cipher encrypts a counter value instead of the plaintext directly, and that output is XORed with the plaintext the same way a native stream cipher would work.

Related terms

AEAD
Authenticated Encryption with Associated Data. Combines confidentiality and integrity in one primitive. AES-GCM and ChaCha20-Poly1305 are the two modern standards. TLS 1.3...
AES-NI
AES New Instructions: hardware AES acceleration introduced on Intel Westmere (2010) and AMD Bulldozer (2011) and now ubiquitous. Single-cycle round operations make...
Block Cipher
A symmetric cipher that operates on fixed-size blocks (typically 64 or 128 bits) under a key. AES is a 128-bit-block cipher; DES...
Constant-Time Crypto
An implementation whose execution time, memory access pattern and power profile do not depend on the secret key or plaintext. The defence...
Mode of Operation
The wrapping protocol that defines how a block cipher handles arbitrary-length data, what IV or nonce is used, and whether integrity is...

Explained in

Your journey to becoming a forensic professional starts here.

Practice with mock tests, learn from structured notes, and get your questions answered by a global forensic community, all in one place.