NEW
Symmetric algorithms that encrypt by combining plaintext with a pseudorandom keystream derived from a shared secret.
DESCRIPTION
Symmetric stream ciphers produce a keystream that is XORed with plaintext, enabling high-speed, byte-level encryption without padding. Designs include synchronous (e.g., ChaCha20) and self-synchronizing variants (e.g., CFB mode). Security depends on keystream unpredictability and strict non-reuse of keys and nonces. Stream ciphers are favored in constrained and high-performance environments and power modern AEADs like ChaCha20-Poly1305. Legacy stream ciphers like RC4 are deprecated due to biases.
ALTERNATIVE DEFINITIONS
Handbook of Applied Cryptography
A stream cipher is a symmetric cipher in which plaintext digits are combined with a pseudorandom cipher digit stream (keystream).
Standard textbook definition emphasizing keystream combination.
OWASP
Stream ciphers require that the same key/nonce pair never be reused, as keystream reuse reveals information about the plaintexts.
Focuses on critical non-reuse property of key/nonce pairs.
RELATED TERMS
Keystream RC4 ChaCha20 Salsa20 One-Time Pad Counter Output Feedback Synchronous Stream Cipher Self-synchronizing Stream Cipher
COMPETING TERMS
Symmetric Block Cipher Algorithms
KNOWLEDGE AREAS
Data Security Software Engineering
TARGET AUDIENCE
Security Architect Cybersecurity Engineer Software Developer Cloud Architect
EXTERNAL SOURCES
- Wikipedia - Stream cipher
- Handbook of Applied Cryptography - Foundational coverage of stream ciphers
- IETF RFC 7539 - ChaCha20 and Poly1305 specification
- OWASP - Best practices for cryptography
TOP QUESTIONS
When should Symmetric Stream Ciphers be used?
Use them for high-speed, low-latency encryption of data streams or variable-length messages, especially where padding overhead is undesirable.
Category: Relevancy
What is the cardinal rule for Symmetric Stream Ciphers?
Never reuse a key/nonce pair. Keystream reuse reveals relationships between plaintexts and can lead to message recovery.
Category: Risks
How do stream ciphers differ from block ciphers?
Stream ciphers process data element-by-element with a keystream; block ciphers operate on fixed-size blocks and often require padding.
Category: Understanding
Which modern stream cipher is widely recommended?
ChaCha20 (often with Poly1305 for authentication) is widely recommended for performance and security.
Category: BestPractices
Are stream ciphers inherently authenticated?
No. They provide confidentiality only unless combined with a MAC or integrated into an AEAD construction.
Category: Misunderstanding
What is a self-synchronizing stream cipher example?
Cipher Feedback (CFB) mode of a block cipher is self-synchronizing, recovering from bit losses by design.
Category: Example
What attacks target poor keystreams?
Biases and correlations allow distinguishing attacks; keystream reuse enables XOR-based plaintext recovery.
Category: Risks
Are stream ciphers good for hardware or software?
They’re efficient in both, but designs like ChaCha20 are particularly fast in software without AES acceleration.
Category: Opinion
Is RC4 still safe as a stream cipher?
No. RC4 is deprecated due to biases and practical attacks; do not use it in new systems.
Category: BestPractices