Cipher Block Chaining (CBC) mode

A block cipher mode in which each plaintext block is XORed with the previous ciphertext block before encryption, starting from an IV, so identical blocks encrypt differently.

Cipher Block Chaining is a confidentiality mode for block ciphers specified in NIST SP 800-38A. Before each plaintext block is encrypted, it is combined by XOR with the previous ciphertext block; the first block is combined with an initialization vector. Because each ciphertext block depends on all the plaintext before it, identical plaintext blocks encrypt differently, removing the pattern leakage of Electronic Codebook mode. SP 800-38A requires the IV to be unpredictable.

The chaining has consequences. Encryption is sequential, though decryption can run in parallel. A corrupted ciphertext block garbles its own plaintext block and flips the matching bits of the next, after which decryption recovers. Messages are padded to whole blocks, and that padding became the target of padding oracle attacks, a form of chosen-ciphertext attack. CBC provides no integrity: an attacker can alter ciphertext to cause predictable changes in the decrypted output, so it needs a separate check such as an HMAC. Newer designs commonly prefer an authenticated encryption mode such as GCM, and TLS 1.3 has no CBC cipher suites.

Exam relevance: a scenario asking which mode hides repeated plaintext without adding integrity is likely to point to CBC. Candidates are expected to know that it chains blocks from an unpredictable IV, and that it should be paired with integrity protection or replaced by an authenticated mode.