ECB mode
Electronic codebook mode: the simplest way to use a block cipher, which encrypts every block separately and so leaks patterns in the data.
Identical blocks encrypt identically, so patterns leak and blocks can be swapped without detection.
In more detail
ECB stands for electronic codebook. Because identical plaintext blocks always give identical ciphertext blocks, repeated structure, such as the outline of an image or repeated database values, stays visible, and blocks can be cut and rearranged without detection. It should never be used for real data, and a review that finds AES in ECB mode should flag it.
Example
Retired: DES, 3DES, RC4, and AES in ECB modeRelated terms
- block cipher mode — The method for using a block cipher such as AES on data longer than one block, such as CBC or GCM.
- CTR mode — Counter mode: a way of using a block cipher that encrypts a running counter to make keystream, then combines that with the message using XOR.
- AES-GCM — AES in Galois/Counter Mode: the most widely used way to encrypt data so that it stays secret and any tampering is detected.
- CBC mode — Cipher block chaining, a way of running a block cipher in which each block of plaintext is mixed with the previous block of ciphertext before it is encrypted.
Taught in
- Symmetric Encryption: AES-GCM & ChaCha20 — Cybersecurity Fundamentals, GRC & Cryptography