package mirage-crypto-rng
Install
    
    dune-project
 Dependency
Authors
Maintainers
Sources
sha256=5430ce3c3e40627d2d67a8decf565a1f612d39bdb33f9b767c3bdb601ff5a196
    
    
  sha512=de029e01cbb8d49f9b8fbcd02ef4777435927118c9ce7a859a8193fdbec30d1a7b3a2964ee8ec722f5fa74fec1bfdc054dcdc97ad1db6e2ced359d6c010c043a
    
    
  doc/mirage-crypto-rng.unix/Mirage_crypto_rng_unix/Getentropy/index.html
Module Mirage_crypto_rng_unix.GetentropySource
A generator using getrandom(3) on Linux, getentropy(3) on BSD and macOS, and BCryptGenRandom() on Windows.
State type for this generator.
Internally, this generator's generate always produces k * block bytes.
generate_into ~g buf ~off n produces n uniformly distributed random bytes into buf at offset off, updating the state of g.
Assumes that buf is at least off + n bytes long. Also assumes that off and n are positive integers. Caution: do not use in your application, use Mirage_crypto_rng.generate_into instead.
reseed ~g bytes directly updates g. Its new state depends both on bytes and the previous state.
A generator is seded after a single application of reseed.
accumulate ~g is a closure suitable for incrementally feeding small amounts of environmentally sourced entropy into g.
Its operation should be fast enough for repeated calling from e.g. event loops. Systems with several distinct, stable entropy sources should use stable source to distinguish their sources.
pools is the amount of pools if any.