The "Two-Time Pad" Problem Stream ciphers are hard to use correctly! For example, you must never encrypt two messages with the same keystream K Suppose P1 and P2 are both encrypted with the same K Then C1 = P1 XOR K, and C2 = P2 XOR K. But then C1 XOR C2 = P1 XOR K XOR P2 XOR K = P1 XOR P2 So the adversary learns the XOR of two plaintexts! If he knows (or can guess) parts of one plaintext, he can learn the corresponding parts of the other. Usually, just knowing the XOR of two plaintexts is enough to recover them both.