Re: short read from /dev/urandom
From: Ulrich Drepper
Date: Fri Jan 14 2005 - 16:17:22 EST
Theodore Ts'o wrote:
What do you think? Does gcc -pg calls sigaction with SA_RESTART, to
avoid changing the behaviour of the programs that it is profiling?
Profiling certainly uses SA_RESTART. But this was just one possible
problem case.
I'm concerned that there is isgnificant code out there relying on the
no-short-read promise. And perhaps more importantly, other
implementations promise the same.
The code in question comes from a crypto library which is in wide use
(http://www.cryptopp.com) and it is using urandom under this assumption.
I fear there is quite a bit more code like this out there. Changing
the ABI after the fact is no good and dangerous in this case.
I know this is making the device special, but I really think the
no-short-reads property should be perserved for urandom.
--
â Ulrich Drepper â Red Hat, Inc. â 444 Castro St â Mountain View, CA â
Attachment:
signature.asc
Description: OpenPGP digital signature