Britannica Sources used in this answer

How does a brute-force attack search through possible encryption keys?

Created from Britannica articles using AI. AI can make mistakes, so verify using Britannica articles.

A brute-force attack is a frontal assault on a cryptosystem that relies on the exhaustive search of the entire key space to uncover the correct encryption key.1

The process functions as follows:

  • Systematic Decryption: The cryptanalyst takes a block of ciphertext and systematically attempts to decrypt it using every possible key in the system's key space, one after another.1
  • Verification: After each decryption attempt, the analyst checks the output to see if it results in meaningful text. If a block of meaningful text is produced, the analyst then tests that specific key against subsequent blocks of ciphertext to verify its validity.1
  • Computational Effort: The security of a system against this attack is defined by its work function, which is the total computational effort required to test all possible keys. If an analyst possesses sufficient time and computing resources, they will eventually identify the correct key.1

Modern systems mitigate this risk by using larger key sizes, such as 128-bit or 2048-bit keys, which make the total number of possible combinations computationally infeasible to search within a reasonable timeframe.1