Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 Ind
 [Top of Book]  [Contents]   [Previous Chapter]   [Next Chapter] 

6 Really random sources
 6.1 The functions

6 Really random sources

This section describes so called "real random sources". It is an extension to the library mechanism of random source objects that uses the devices /dev/random and /dev/urandom available on Linux systems (and maybe on other operating systems) providing random numbers that are impossible to predict. The idea is that such sources of random numbers are useful to produce unpredictable secret keys for cryptographic applications.

6.1 The functions

6.1-1 RandomSource
‣ RandomSource( r, dev )( method )

Returns: a real random source object or fail

The first argument r must be the GAP filter IsRealRandomSource and the second either the string random or the string urandom. A real random source object is created that draws its random numbers from the kernel devices /dev/random and /dev/urandom respectively. Whereas /dev/urandom always provides random numbers of not guaranteed "quality", the device /dev/random measures its entropy and produces guaranteed unpredictable numbers. However, it might block until enough "random" events (like mouse movements) have been accumulated.

 [Top of Book]  [Contents]   [Previous Chapter]   [Next Chapter] 
Goto Chapter: Top 1 2 3 4 5 6 7 8 9 10 11 Ind

generated by GAPDoc2HTML