LWN.net Logo

Not detected by testing

Not detected by testing

Posted May 14, 2008 11:27 UTC (Wed) by endecotp (guest, #36428)
Parent article: Cryptographic weakness on Debian systems

Does openssl have a test suite?  Does it generate a large number of keys and look for
duplicates?

It's easy to suggest this with the benefit of hindsight, and difficult to know whether it
would have been obvious in advance.  But I do know that when I have used hash functions (in
non-security applications) I have sometimes studied whether they are generating sufficiently
well distributed results.


(Log in to post comments)

Not detected by testing

Posted May 15, 2008 0:32 UTC (Thu) by erich (subscriber, #7127) [Link]

Note that we're talking about the seeding here. The seeding was pretty much done only by the
PID. If you had done a test suite, it would have been very unlikely you had detected a
dependency on the PID except by doing like 32k runs until the same PID is used again.
Even if you had been testing the RNG separately from all other stuff that would seem pretty
much overkill to do some 32k runs of the test app and compare the results for duplicates or
similarities.

Not detected by testing

Posted May 15, 2008 13:19 UTC (Thu) by kevinbsmith (guest, #4778) [Link]

How about a test that generates two keys in a row, within the same process, and makes sure
they are not identical to each other. If salt is involved, take that into account rather than
doing a bitwise comparison.

That seems like a pretty reasonable test at the library level, to ensure the key really is a
key and not a buffer full of zeros.

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds