thraxil wrote:
if the key is longer than the message being encrypted and the key is perfectly random, it is provably unbreakable (it's just a one-time pad).
This is true if used as a one-time pad: one-time. In the original post, I got the impression that this encryption is to be used many times, thus falling prey to your second caveat: the key being shorter than the message makes the message insecure. In this case, the cracker can just concatenate the messages (well, it's often more complex than that, but you get the idea).
If, however, there were some form of key exchange like the Diffie-Hellman method, then a secure, random key can be distributed, but that seems to take us back to the original problem of creating security because you have to settle on a method of encrypting the random key and you can't just use it to XOR itself :) If you encrypt the random key, you may as well just encrypt the original data.
Cheers,
Ovid
Join the Perlmonks Setiathome Group or just click on the the link and check out our stats.
In reply to Re: Re: How secure is XOR encryption?
by Ovid
in thread How secure is XOR encryption?
by talexb
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |