[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: /dev/random for FreeBSD [was: Re: /dev/random for Linux]




Tom Weinstein writes:
> One problem with this scheme is that if multiple processes have
> /dev/random open you can block unexpectedly.  If I try to avoid blocking
> by first checking if entropy is available there's a race condition if
> another process reads from the device.  Is there another way to avoid
> blocking?

Yeah. Use non-blocking I/O. Its in every version of Unix I've touched
for over a decade.

.pm