Conversation
Signed-off-by: Joe Richey <joerichey@google.com>
| //! | Solaris, illumos | `*‑solaris`, `*‑illumos` | [`getrandom()`][9] if available, otherwise [`/dev/random`][10] | ||
| //! | Fuchsia OS | `*‑fuchsia` | [`cprng_draw`][11] | ||
| //! | Redox | `*‑redox` | [`rand:`][12] | ||
| //! | Redox | `*‑redox` | [`/dev/urandom`][12] |
There was a problem hiding this comment.
We may need to update the documentation link here
There was a problem hiding this comment.
The link simply points to the relevant Redox source code. It would be nice to replace it with a proper documentation link, but AFAIK such documentation currently does not exist.
There was a problem hiding this comment.
@jackpot51 does Redox have any docs describing either rand: or /dev/urandom?
|
/dev/urandom is now a symlink to rand:, and rand: is always a non-blocking CPRNG |
newpavlov
left a comment
There was a problem hiding this comment.
IIUC /dev/urandom was added mostly for compatibility purposes and reading rand: is more idiomatic. From practical point of view both options are equivalent to each other, so I am fine with this change.
@jackpot51
BTW how Redox handles entropy pool initialization on system startup? The preferred behavior for us would be for it to block rand:/dev/urandom reading until the pool gets properly initialized.
|
@newpavlov rand: (and /dev/urandom with it being a symlink) will not return any data until it is initialized. It will block on read. |
|
Thanks @josephlr ! |
Signed-off-by: Joe Richey <joerichey@google.com>
From briansmith/ring#1341 apparently on Redox the
/dev/urandomdevice now exists. Changing the implementation for consistency between RNG crates.@jackpot51 does this look good to you? Also, where is this device documented?
Signed-off-by: Joe Richey joerichey@google.com