Entropy in the Linux Kernel: Difference between revisions
Created page with "Entropy is required to generate random numbers. {{code|/dev/random}} and {{code|/dev/urandom}} on Linux provide a way to access random numbers. Both devices are supplied by th..." |
m wording |
||
| Line 1: | Line 1: | ||
Entropy is required to generate random numbers. | Entropy is required to generate good random numbers. Modern operating systems will use physical hardware as sources for entropy and the 'randomness' goes into an entropy pool for future use. | ||
== Entropy | On Linux, {{code|/dev/random}} and {{code|/dev/urandom}} are pseudo devices that provide random numbers. Both devices are supplied by the kernel's PRNG, though {{code|/dev/random}} will block when the entropy pool is depleted while {{code|/dev/urandom}} will continue to generate random numbers. | ||
== Linux Entropy Pool == | |||
You can see the size of the entropy pool size in linux by running: | You can see the size of the entropy pool size in linux by running: | ||
Revision as of 07:37, 21 September 2015
Entropy is required to generate good random numbers. Modern operating systems will use physical hardware as sources for entropy and the 'randomness' goes into an entropy pool for future use.
On Linux, /dev/random and /dev/urandom are pseudo devices that provide random numbers. Both devices are supplied by the kernel's PRNG, though /dev/random will block when the entropy pool is depleted while /dev/urandom will continue to generate random numbers.
Linux Entropy Pool
You can see the size of the entropy pool size in linux by running:
cat /proc/sys/kernel/random/poolsize
The number of 'bits' of entropy can be seen at:
cat /proc/sys/kernel/random/entropy_avail