# DES attack with known partial plaintext

Consider a system where DES is used to encrypt HTTP GET requests. The first three bytes correspond to the character sequence "GET". How many encrypted messages is it necessary to intercept to be sure to guess the key used to encryption ?

• What have you already attempted in solving this homework problem? Commented Apr 29, 2023 at 15:27
• The key size is 56 bits, so we have 2^56 keys, the block size is 64 bit so we have 2^64 ciphertexts. The first 24 bit are known so we have 2^64 / 2^24 = 2^40 possible ciphertexts. We also know that there are 2^56 / 2^40 = 2^16 ciphertexts per key. With an additional intercepted message we can reduce the previous value to 2^16/2^40 = 2^-24. In this way if we find a valid key, it will be the correct key. I am not sure about my solution beacuse increasing the number of fixed bits would require more intercepted messages Commented Apr 29, 2023 at 16:52

So, in this situation, an incorrect guess at the key happens to have the first three characters of the plaintext as "GET" with probability $$2^{-24}$$ (because we have 24 known bits).