In: Computer Science
Cryptography***
For DES, what is the probability that two different keys will encrypt atleast 1 plaintext message to the same ciphertext output?
Given you know about the double encryption you would look for two keys, which actually means more than just a factor of two. Needing to know the two correct key values means the same as needing to know one double length key value. In some algorithms, like the one pad cipher, this means an effectively same length key anyway, but usually not. In general there may be some combinations of two n-bit keys that have the same effect as one single key, but more often than not no N-bit key on a single pass will do the same as a combination of two keys.
The bit strength nevertheless is better doubled by using an algorithm with the wider key length, which often is available, ie AES with different key lengths. It much better ensures there is no such collision of keys having the same effect.I’d not bother thinking about adding security by any additional procedures ourside of an ecryption algorithm as that and any other ideas to harden an encryption algorithm already is done by the cryptography experts. No matter also, if you make your additional steps a secret. Any closed source cryptography or secret is bound to be less safe as less experts can test it against a weaknesses. And then overall, you could have any weakness outside of the theoretical idea in CPU architectural bugs being exploited, security bugs of the OS cryptographic base system, etc. even just having the intermediate message makes it less hard than all the intermediate blocks in memory during a single algorithm usage, so passing this intermediate message between the two stages would need a safe tunnel, ideally. Then it’s easier to use one algorithm.