Author Theodore Tso
Recipients Theodore Tso, dstufft, larry, vstinner
Date 2016-06-08.19:02:15
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
Larry, at least on FreeBSD, it sounds like the implementation could just the kern.random.sys.seeded sysctl, and return <something>.  (Note: what is the proposed behaviour if the PRNG is not seeded?  Return Null?)

As far as OpenBSD is concerned, it's true that it's getentropy(2) never blocks.  But that's because OpenBSD assumes that the bootloader can read a seeded entropy file from the previous boot session, and that the CD-ROM installer will be able to gather enough entropy to save a entropy file from the beginning of the installation.    So if you don't have worry about booting your OS on an ARC Internet of Things device, you can afford to make certain simplifying assumptions.

Could Linux on x86 do something similar (read the entropy file in the bootloader)?  Sure, the design isn't difficult.  If someone can fund the headcount to do the work, I'd be happy to help supervise the GSOC intern or work with some engineer at some other company who is interested in getting a change like this upstream.  But there will still be cases where getrandom(2) could block, simply because I can't control all of the hardware platforms where Linux might be ported to.   The real problem is that since on real hardware platforms it's only a problem in very early boot, it's hard to make a business case to invest in solving this problem.
Date User Action Args
2016-06-08 19:02:15Theodore Tsosetrecipients: + Theodore Tso, vstinner, larry, dstufft
2016-06-08 19:02:15Theodore Tsosetmessageid: <>
2016-06-08 19:02:15Theodore Tsolinkissue27266 messages
2016-06-08 19:02:15Theodore Tsocreate