Re: Fast random generator was: Re: Ideas for v2.1
Theodore Y. Ts'o (tytso@mit.edu)
Tue, 2 Jul 1996 14:07:48 -0400
/dev/urandom is not intended to be used for getting random data for
filling a disk. If you want to do this, write a quick user-mode program
which sends to stdout a pseudo-random stream. For example:
int main(int argc, char **argv)
{
long r;
int ret;
while (1) {
r = random();
ret = write(1, r, sizeof(r));
if (ret <= 0)
break;
}
return 0
}
There's no need for a kernel based /dev/frandom.
- Ted