aboutsummaryrefslogtreecommitdiffstats
path: root/src/librandom/random_init.c
Commit message (Collapse)AuthorAgeFilesLines
* Prepare for 2.12.0.0. librandom revamp.Laurent Bercot2022-04-091-72/+0
| | | | Signed-off-by: Laurent Bercot <ska@appnovation.com>
* Don't write to /dev/urandom. (It's useless or even harmful.)Laurent Bercot2022-03-271-4/+0
|
* Don't touch /dev/urandom when getrandom() existsLaurent Bercot2021-01-151-9/+8
|
* Fix iobufferk_init on recent Linux; remove last superfluous coeLaurent Bercot2020-12-041-13/+5
|
* Add egidingroups sysdeps, change fd_close() to void and saving errno, ↵Laurent Bercot2017-07-161-2/+0
| | | | propagate changes
* add arc4random_addrandom sysdep; next batch of types changes.Laurent Bercot2017-02-151-0/+2
| | | | | The library isn't supposed to be functional yet: there are still a lot of type mismatches.
* random_init: do not fail if we can't write to /dev/urandomLaurent Bercot2016-11-031-4/+3
|
* This one escaped the previous commit: random_init changesLaurent Bercot2016-10-241-10/+14
|
* Fix headers in random_init.c; add a workaround for (pathological) ↵Laurent Bercot2016-10-161-0/+6
| | | | getrandom() without /dev/urandom
* Add a cast to arc4random_addrandom invocation to make clang happyLaurent Bercot2016-10-141-1/+1
|
* Include skalibs/nonposix.h so BSDs can find arc4randomLaurent Bercot2016-10-141-0/+1
|
* Clean up and modernize librandom.Laurent Bercot2016-10-141-0/+75
Correct random number generation has historically been suprisingly painful to achieve. There was no standard, every system behaved in a subtly different way, and there were a few userland initiatives to get decent randomness, all incompatible of course. The situation is a bit better now, we're heading towards some standardization. The arc4random() series of functions is a good API, and available on a lot of systems - unfortunately not Linux, but on Linux the new getrandom() makes using /dev/random obsolete. So I removed the old crap in librandom, dropped EGD support, dropped dynamic backend selection, made a single API series (random_* instead of goodrandom_* and badrandom_*), added an arc4random backend and a getrandom backend, and defaulted to /dev/urandom backed up by SURF in the worst case. This should be much smaller and logical. However, it's a major API break, so the skarnet.org stack will be changed to adapt.