# Can I decrypt the message having it encrypted with different keys?

I have some encrypted binary data I want to decrypt. I know nothing about it, but I can get it encrypted with as many different (random, unknown) symmetric keys as I want. The keys are long enough to not get repeated. Something like this:

$A_1 = Data ⊕ Key_1\\ A_2 = Data ⊕ Key_2\\ A_3 = Data ⊕ Key_3\\ …\\ A_n = Data ⊕ Key_n$

Is it possible to get $Data$ just having the $A$s?

Thanks

• Maybe this question can help you: crypto.stackexchange.com/questions/12281/…. Also, if you want to encrypt A using only the same cipher, then that does not increase the time to encrypt the text with brute force. Because for most ciphers, if $A_1 = E(E(A_0, K_0), K_1)$, it can be reduced to $A_1 = E(A_0, K')$ (E is the cipher, $K_x$ the keys), so you don't search for two keys, you still just need one. If someone thinks I am wrong (I am doubting myself at the moment), then please prove me wrong. May 17 '14 at 10:48
• @Sirac : $\;\;\;$ The DES permutations are a non-empty subset of the group of all permutations of $\{\hspace{-0.02 in}0,\hspace{-0.05 in}1\hspace{-0.03 in}\}^{\hspace{-0.02 in}64}$. $\:$ Since that group is finite, composing a non-identity element of that group with itself sufficiently many times gives $\:$ (continued ...) $\;\;\;\;\;\;\;$
– user991
May 17 '14 at 13:29
• (... continued ) $\:$ that element's inverse; and then one more time gives the identity element. $\:$ Thus if DES had the property you describe, then the DES permutations would be a group under composition. $\:$ However, it is known that DES is not a group. $\;\;\;$
– user991
May 17 '14 at 13:30
• No. As long as only 1 of the 3 elements is known, $Data$ is not immediately recoverable… you’ld need either $A_n$ or $Key_n$ for that. Yet, this encoding could be trivially broken nevertheless if it weren’t for the fact that you wrote The keys are long enough to not get repeated. That’s called a one-time-pad. It may be interesting for you to check related Q&As and to learn about OTP security properties. May 17 '14 at 13:31
• @Wizardy : $\;\;\;$ How much is the situation like what you wrote? $\:$ In particular, are the cipher texts really equal to [data xor key]? $\;\;\;\;\;\;\;$
– user991
May 17 '14 at 13:33

If the keys are at least as long as the data (which is confirmed in the comments), and the keys are chosen randomly and independent of each other, no there is no way to get the data. Even if you had infinitely many encryptions.

This is because this type of encryption, called the one time pad, is perfectly secure.