The Answer I'm referring to: https://security.stackexchange.com/a/5357/61443

My objections to it are:

  1. While the OP is asking about recovering the AES keys, his setup is also vulnerable to a Ciphertext Indistinguishably attack.

  2. Dangerously for other users / DB admins who find this question is that the answer of "Nah, everything's fine" is dangerously misleading without also mentioning IVs, and making sure your PRNG has a good entropy source somewhere in the body of the question.

So, do others agree with my assessment, and if so, can we change it?

  • 4
    Why not make a reply calling him out? And reply as a comment as well, stating that he's wrong, etc. Mar 15, 2016 at 14:49
  • I did, but since the post is 5 years old, I have low hopes that he'll log in to see it. -- actually, he logged in January 2016, so maybe there's some hope. Mar 15, 2016 at 14:53
  • Make an answer calling him out as well. Mar 15, 2016 at 14:56
  • Ok, I'll do that shortly. Mar 15, 2016 at 14:58
  • If his concern is security of the key, as the questioner explicitly states, then the accepted answer is technically correct. It ignores the Indistinguishability attack, but that may not be a threat that concerns him. Mar 29, 2016 at 1:01

2 Answers 2


Ok, on Mark Buffalo's suggestion, I posted a Community Wiki Answer.

I do not feel that I am enough of an expert here, so I ask that other people look over it and fix any errors or inaccuracies.


That answer is not incorrect, but it is incomplete. As you noticed there is a serious design flaw in the implementation described in the question. The question does not explicitly ask about this weakness, and the answer does not mention it.

Though technically a correct answer to the question as it was asked, it is indeed a disservice to provide the answer as such without pointing out the quite severe weakness.

I edited your answer to address one minor issue. But even before my edit it was a better answer than the accepted one.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .