4 ms·
Why is rng not handled by a standard library or with a call to /dev/*random? Feels weird to me that average userspace code should even know about CPU instructio
by krastanov 6y ago
Why is rng not handled by a standard library or with a call to /dev/*random? Feels weird to me that average userspace code should even know about CPU instructions.
- fluix 6y agoAuthor here. Not particularly sure myself, even systemd says it only does so because it does things early in the boot process[1]. Using it for it's purpose here is probably alright, but the odd part is prioritizing it[2] over /dev/urandom. [1]: https://github.com/systemd/systemd/blob/301e7cd047c8d07715d5dc37f713e8aa031581b4/src/basic/random-util.c#L43 https://github.com/systemd/systemd/blob/301e7cd047c8d07715d5... [2]: https://github.com/json-c/json-c/blob/31f1ab2be1142d982fc9b8c8913bfd1233599ebb/random_seed.c#L230 https://github.com/json-c/json-c/blob/31f1ab2be1142d982fc9b8...