1{-# LANGUAGE CPP, ForeignFunctionInterface, BangPatterns, ScopedTypeVariables #-}
3 Maintainer: Thomas.DuBuisson@gmail.com
7 Obtain entropy from system sources or x86 RDRAND when available.
11 - Windows via CryptoAPO
12 - *nix systems via @\/dev\/urandom@
14 - Xen only when RDRAND is available.
20 module System.EntropyWindows
22import System.EntropyWindows
24 module System.EntropyNix
26import System.EntropyNix
29import qualified Data.ByteString as B
31-- |Inefficiently get a specific number of bytes of cryptographically
32-- secure random data using the system-specific facilities.
34-- Use '/dev/urandom' on *nix and CryptAPI when on Windows. In short,
35-- this entropy is considered cryptographically secure but not true
37getEntropy :: Int -> IO B.ByteString
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list