Hacker News new | ask | show | jobs
by crapto 1237 days ago
It will be slower to encrypt and decrypt, and a bit more complicated due to the multiple layers and managing the keys to encrypt and decrypt it all.

There's no disadvantage in terms of algorithmic secrecy.

2 comments

I agree. There are various complexity downsides (implementation, key management, etc) but it should be fine from a practical cryptographic security perspective.

While I can't offer you a formal cryptanalysis, I do have a handwave-y thought experiment & proof by contradiction for intuition:

Consider two encryption algorithms A[...] and B[...] that are "good" in the standard ways (adversary cannot decrypt messages without keys, keys cannot be leaked by chosen plaintext attack, etc).

If putting A inside of B like B[A[...]] renders the system insecure, it would imply that B[...] was not a "good" encryption function! (if it was good, it would not break just because the input message happens to be the output of A[...]).

Therefore by handwave-y proof by contradiction, if A[...] and B[...] are "good", then A[B[...]] should be OK.

(Disclaimer: Again, this is a casual thought experiment and not real cryptanalysis. This result may not be true under formal cryptanalysis.)

Thank you. Since i'm using this to encrypt backups, speed is not a problem.