RFC: initialize /dev/urandom, is it necessary? Can we do it in a better way?

Roberto A. Foglietta roberto.foglietta at gmail.com
Tue Sep 19 12:20:13 UTC 2023


On Tue, 19 Sept 2023 at 14:06, Roberto A. Foglietta
<roberto.foglietta at gmail.com> wrote:
>
> On Tue, 19 Sept 2023 at 13:30, Rob Landley <rob at landley.net> wrote:

> dmesg | sha512sum > /dev/urandom

Oops, sorry because the sha512sum command-line prints a human readable
16 chars based string

dmesg | pigz -4c | dd bs=64 skip=1 > /dev/urandom

is a far better option. Obviously, in the kernel sha512sum() provides
a binary stream not a text.

The good habits to have a basic /dev populated with those few devices
that always exist like /dev/urandom allows the seeding even before the
mount procedure.

Best regards, R-


More information about the busybox mailing list