[Cryptography] Dieharder & symmetric cryptosystems

Ray Dillinger bear at sonic.net
Wed Mar 16 01:25:18 EDT 2022



On 3/14/22 23:24, Ray Dillinger wrote:
> If WEAK results on a particular test are persistent across several
> different runs and regardless of whether we increase the sample size,
> then that's something that has to be fixed.

I have found a genuine problem here but first, I don't think it's the same one that 
OP intended to report, and second, I assess it as a problem with Dieharder not a 

problem with /dev/urandom.  I've pasted a repeated tests (specifically
test 201,
the 'rgb_minimum_distance' test) against /dev/urandom input.  As you can
see,
'/dev/urandom' fails every time.

But note that the p-value assessment is 0.0000, which means dieharder is
seeing
a series of numbers which it thinks have ABSOLUTELY no chance of coming
from
a random generator.  Also of note, this test is now failing, with
p-value assessment
of 0.0000, on every generator in the dieharder suite.

This indicates to me that there is some problem in the way this
particular test
is implemented, entirely separate from any problem with /dev/urandom.

                        Bear


-----------------------------------------Paste follows
-----------------------------------
$ cat /dev/urandom | dieharder -g200 -d201 -k2 -Y1;
  cat /dev/urandom | dieharder -g200 -d201 -k2 -Y1;
  cat /dev/urandom | dieharder -g200 -d201 -k2 -Y1;
  cat /dev/urandom | dieharder -g200 -d201 -k2 -Y1;
  cat /dev/urandom | dieharder -g200 -d201 -k2 -Y1;
  cat /dev/urandom | dieharder -g200 -d201 -k2 -Y1
#=================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G.
Brown        #
#=================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  3.41e+07  |3141542943|
#=================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=================================================#
rgb_minimum_distance|   0|     10000|    1000|0.00000000|  FAILED  
#=================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G.
Brown        #
#=================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  3.64e+07  |1726740133|
#=================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=================================================#
rgb_minimum_distance|   0|     10000|    1000|0.00000000|  FAILED  
#=================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G.
Brown        #
#=================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  3.52e+07  |3912038150|
#=================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=================================================#
rgb_minimum_distance|   0|     10000|    1000|0.00000000|  FAILED  
#=================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G.
Brown        #
#=================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  4.22e+07  |1020210298|
#=================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=================================================#
rgb_minimum_distance|   0|     10000|    1000|0.00000000|  FAILED  
#=================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G.
Brown        #
#=================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  4.35e+07  | 749211463|
#=================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=================================================#
rgb_minimum_distance|   0|     10000|    1000|0.00000000|  FAILED  
#=================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G.
Brown        #
#=================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  4.16e+07  |4293996729|
#=================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=================================================#
rgb_minimum_distance|   0|     10000|    1000|0.00000000|  FAILED 
$


More information about the cryptography mailing list