rngtest - Check the randomness of data using FIPS 140-2 tests

Synopsis

Description

Options

Statistics

Exit Status

See Also

Authors

rngtest[-cn|--blockcount=n] [-bn|--blockstats=n] [-tn|--timedstats=n] [-p|--pipe] [-?] [--help] [-V] [--version]

rngtestworks on blocks of 20000 bits at a time, using the FIPS 140-2 (errata of 2001-10-10) tests to verify the randomness of the block of data.It takes input from

stdin, and outputs statistics tostderr, optionally echoing blocks that passed the FIPS tests tostdout(when operating inpipe mode). Errors are sent tostderr.At startup,

rngtestwill trow away the first 32 bits of data when operating inpipe mode. It will use the next 32 bits of data to bootstrap the FIPS tests (even when not operating inpipe mode). These bits are not tested for randomness.Statistics are dumped to

stderrwhen the program exits.

-p,--pipeEnable pipe mode. All data blocks that pass the FIPS tests are echoed tostdout, andrngtestoperates in silent mode.-cn,--blockcount=n(default: 0)Exit after processing n input blocks, if n is not zero. -bn,--blockstats=n(default: 0)Dump statistics every n blocks, if n is not zero. -tn,--timedstats=n(default: 0)Dump statistics every n secods, if n is not zero. -?,--helpGive a short summary of all program options. -V,--versionPrint program version

rngtestwill dump statistics tostderrwhen it exits, and when told to byblockstatsortimedstats.

FIPS 140-2 successesandFIPS 140-2 failurescounts the number of 20000-bit blocks either accepted or rejected by the FIPS 140-2 tests. The other statistics show a breakdown of the FIPS 140-2 failures by FIPS 140-2 test. See the FIPS 140-2 document for more information (note that these tests are defined on FIPS 140-1 and FIPS 140-2 errata of 2001-10-10. They were removed in FIPS 140-2 errata of 2002-12-03).The speed statistics are taken for every 20000-bit block trasferred or processed.

0if no errors happen, and no blocks fail the FIPS tests.

1if no errors happen, but at least one block fails the FIPS tests.

10if there are problems with the parameters.

11if an input/output error happens.

12if an operating system or resource starvation error happens.

random(4), rngd(8)

FIPS PUB 140-2 Security Requirements for Cryptographic Modules, NIST, http://csrc.nist.gov/cryptval/140-2.htm

Henrique de Moraes Holschuh <hmh@debian.org>

rng-tools 2 |
RNGTEST (1) | March 2004 |