To check the security of mnemonics generation, we will test the library randombytes, that generates entropy. The test for verification was taken from the official NIST site csrc.nist.gov
Download this repository. On command line, type in the following commands:
$ cd nist/sts-2.1.2
$ make -f makefileReturn to the directory above in nist and run the script run-test.sh.
$ cd ..
$ sh run-test.shThe file will start generating 1,500,000 bytes of random data and save it in the output file.
Further testing itself will start.
Choose the test method ([0] Input File):
$ ./assess 1200000
...
Enter Choice: 0Enter the path to the file:
$ ...
User Prescribed Input File: ../outputChoose the type of test ([01] Frequency):
$ ...
Enter Choice: 1Enter the test parameters:
$ ...
Select Test (0 to continue): 0
How many bitstreams? 10Choose a file type. In our case, this is Binary ([1] Binary - Each byte in data file contains 8 bits of data):
$ ...
Select input mode: 1Testing has begun. At its end, a file with the test result will open.
Results are written to the file /lumi-web-core/nist/sts-2.1.2/experiments/AlgorithmTesting/finalAnalysisReport.txt