![](bg1.png)
Revisiting the DFT Test in the NIST SP 800-22 Randomness Test Suite
Hiroki Okada
a
and Kazuhide Fukushima
KDDI Research, Inc., Fujimino-shi, 356-8502 Japan
Keywords:
Randomness, RNG, NIST SP 800-22, Discrete Fourier Transformation.
Abstract:
The National Institute of Standards and Technology (NIST) released SP 800-22, which is a test suite for
evaluating pseudorandom number generators for cryptographic applications. The discrete Fourier transform
(DFT) test, which is one of the tests in NIST SP 800-22, was constructed to detect some periodic features of
input sequences. There was a crucial problem in the construction of the DFT test: its reference distribution
of the test statistic was not derived mathematically; instead, it was numerically estimated. Thus, the DFT
test was constructed under the assumption that the pseudorandom number generator (PRNG) used for the
estimation generated “truly” random numbers, which is a circular reasoning. Recently, Iwasaki (Iwasaki,
2020) performed a novel analysis to theoretically derive the correct reference distribution (without numerical
estimation). However, Iwasaki’s analysis relied on some heuristic assumptions.
In this paper, we present theoretical evidence for one of the assumptions. Let x
0
,··· ,x
n−1
be an n-bit input
sequence. Its Fourier coefficients are defined as F
0
,...,F
n−1
. Iwasaki assumed that
∑
n
2
−1
j=0
|F
j
|
2
= n
2
/2. We
use a quantitative analysis to show that this holds when n is sufficiently large. We also verify that our analysis
is sufficiently accurate with numerical experiments.
1 INTRODUCTION
Random numbers are used in many applications, such
as cryptography and numerical simulations. However,
it is not easy to generate “truly” random sequences.
Pseudorandom number generators (PRNGs) generate
sequences by iterating a recurrence relation; there-
fore, the sequences are produced deterministically
and are not “truly” random. The binary “truly” ran-
dom sequence is defined as the sequence of random
variables that have a probability of exactly
1
2
of being
“0” or “1” and are mutually independent: We can
write an n-bit “truly” random sequence as ε
0
,.. .,ε
n
iid
∼
U({0,1}).
NIST SP 800-22 (Rukhin et al., 2010; Bassham III
et al., 2010) is a well-known statistical test suite
for evaluating pseudorandom number generators for
cryptographic applications. This test suite consists of
15 tests, and every test is a hypothesis test, where the
hypothesis is that the input sequence is truly random.
If this hypothesis is not rejected in any of the tests, it
is concluded that the input sequences are random.
The discrete Fourier transform (DFT) test in NIST
SP 800-22 is of interest to us. This test was con-
structed to detect periodic features in an input se-
a
https://orcid.org/0000-0002-5687-620X
quence. It performs discrete Fourier transformation
on input sequences and constructs the test statistic
from the Fourier coefficients.
Kim et al. (Kim et al., 2003; Kim et al., 2004)
reported that the DFT test in the original NIST SP
800-22 (Rukhin et al., 2010) has a crucial theoretical
problem. They reported that the reference distribution
of the test statistic of the DFT test was erroneously de-
rived. Kim et al. numerically estimated the distribu-
tion of the test statistic with sequences generated with
a more accurate PRNG and proposed a new DFT test
with an estimated distribution. Hamano (Hamano,
2005) also performed an analysis on the distribution
of the Fourier coefficients in the original DFT test
and made the DFT test problems clearer; however,
the theoretical distribution of the test statistic was
not derived. In 2005, in response to these reports,
NIST revised the DFT test according to the report of
Kim et al. and published NIST SP 800-22 version
1.7. The DFT test has not been subsequently revised.
Pareschi et al. (Pareschi et al., 2012) reviewed the
DFT test included in NIST SP 800-22 version 1.7, and
they reported a more accurate numerical estimation
on the reference distribution of the DFT test than
that given by Kim et al. (Kim et al., 2003; Kim
et al., 2004). Okada and Umeno (Okada and Umeno,
2017) proposed another test based on discrete Fourier
366
Okada, H. and Fukushima, K.
Revisiting the DFT Test in the NIST SP 800-22 Randomness Test Suite.
DOI: 10.5220/0011626300003405
In Proceedings of the 9th International Conference on Information Systems Security and Privacy (ICISSP 2023), pages 366-372
ISBN: 978-989-758-624-8; ISSN: 2184-4356
Copyright
c
2023 by SCITEPRESS – Science and Technology Publications, Lda. Under CC license (CC BY-NC-ND 4.0)