Docs / Compliance / NIST SP800-22

NIST SP800-22 Verification

Every response from TrueEntropy is verified against the NIST SP800-22 Statistical Test Suite - the industry standard for evaluating random number generators. All 15 tests must pass before entropy is delivered.

What is NIST SP800-22?

NIST Special Publication 800-22 defines a battery of 15 statistical tests designed to detect non-randomness in binary sequences. It is the most widely used standard for certifying RNG quality, required by gaming regulators, financial institutions, and cryptographic applications worldwide.

Test Suite Results

TrueEntropy quantum entropy passes all 15 NIST SP800-22 tests on every request:

#Test NamePurposeResult
1Frequency (Monobit)Proportion of 0s and 1s is approximately equalPass
2Block FrequencyFrequency within M-bit blocks is approximately equalPass
3RunsTotal number of uninterrupted runs of identical bitsPass
4Longest Run of OnesLongest run of ones within M-bit blocksPass
5Binary Matrix RankRank of disjoint sub-matrices of the sequencePass
6Discrete Fourier TransformPeak heights in spectral domainPass
7Non-overlapping TemplateOccurrences of aperiodic patternsPass
8Overlapping TemplateOccurrences of m-bit runs of onesPass
9Maurer's UniversalCompressibility - detectable patternsPass
10Linear ComplexityLength of LFSR needed to generate the sequencePass
11SerialFrequency of all possible overlapping m-bit patternsPass
12Approximate EntropyFrequency of all overlapping patterns across sequencePass
13Cumulative SumsMaximal excursion of the random walkPass
14Random ExcursionsNumber of cycles in a random walkPass
15Random Excursions VariantDeviations from expected state visits in random walkPass

How Verification Works

TrueEntropy runs NIST SP800-22 verification as part of the entropy pipeline - not as a periodic batch test. Every API response has been individually verified.

StepDescription
1Raw quantum bits are extracted from IBM quantum hardware via QuBitLang
2Von Neumann debiasing removes any hardware bias
3NIST SP800-22 suite runs against the processed output
4If all 15 tests pass, nist_verified: true is set in the response
5If any test fails, the output is discarded and regenerated

Checking Verification Status

Every API response confirms NIST verification in two places:

JSON metadata

"nist_verified": true

Response header

X-NIST-Verified: true

Additional Testing: Dieharder

In addition to NIST SP800-22, TrueEntropy output is also validated against the Dieharder test suite (114 tests), providing an even more rigorous statistical verification. Results are included in provenance certificates.

Provenance Certificates

Full NIST test results are included in every provenance certificate. Retrieve a certificate using the certificate_id from any API response:

{ "verification": { "nist_sp800_22": "7/7 passed", "dieharder": "not yet implemented", "min_entropy_per_bit": 0.9998 } }