Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

include dieharder randomness check #9

Open
garlick opened this issue Apr 13, 2016 · 0 comments
Open

include dieharder randomness check #9

garlick opened this issue Apr 13, 2016 · 0 comments

Comments

@garlick
Copy link
Member

garlick commented Apr 13, 2016

It might be useful to include in our test suite scripts that run the dieharder PRNG test suite against disk images fuzzed with scrub's random pass.

I borrowed scrub's random fill algorithm (based on /dev/urandom seeded aes counter) in another project and ran it through. "fuzz" is just a program that emits infinite randomness on stdout, while "generator 200" is dieharder's raw stdin mode:

$ fuzz | dieharder -g 200 -a
#=============================================================================#
#            dieharder version 3.31.1 Copyright 2003 Robert G. Brown          #
#=============================================================================#
   rng_name    |rands/second|   Seed   |
stdin_input_raw|  1.95e+07  |1781118548|
#=============================================================================#
        test_name   |ntup| tsamples |psamples|  p-value |Assessment
#=============================================================================#
   diehard_birthdays|   0|       100|     100|0.88369892|  PASSED  
      diehard_operm5|   0|   1000000|     100|0.27636079|  PASSED  
  diehard_rank_32x32|   0|     40000|     100|0.83032047|  PASSED  
    diehard_rank_6x8|   0|    100000|     100|0.56150300|  PASSED  
   diehard_bitstream|   0|   2097152|     100|0.06602982|  PASSED  
        diehard_opso|   0|   2097152|     100|0.19779936|  PASSED  
        diehard_oqso|   0|   2097152|     100|0.91922195|  PASSED  
         diehard_dna|   0|   2097152|     100|0.96128960|  PASSED  
diehard_count_1s_str|   0|    256000|     100|0.89495422|  PASSED  
diehard_count_1s_byt|   0|    256000|     100|0.99865983|   WEAK   
 diehard_parking_lot|   0|     12000|     100|0.43795973|  PASSED  
    diehard_2dsphere|   2|      8000|     100|0.95357150|  PASSED  
    diehard_3dsphere|   3|      4000|     100|0.26285041|  PASSED  
     diehard_squeeze|   0|    100000|     100|0.46825150|  PASSED  
        diehard_sums|   0|       100|     100|0.75424165|  PASSED  
        diehard_runs|   0|    100000|     100|0.08168809|  PASSED  
        diehard_runs|   0|    100000|     100|0.79396703|  PASSED  
       diehard_craps|   0|    200000|     100|0.68331237|  PASSED  
       diehard_craps|   0|    200000|     100|0.78869877|  PASSED  
 marsaglia_tsang_gcd|   0|  10000000|     100|0.58000065|  PASSED  
 marsaglia_tsang_gcd|   0|  10000000|     100|0.82667972|  PASSED  
         sts_monobit|   1|    100000|     100|0.39302301|  PASSED  
            sts_runs|   2|    100000|     100|0.66066020|  PASSED  
          sts_serial|   1|    100000|     100|0.59349971|  PASSED  
          sts_serial|   2|    100000|     100|0.63188867|  PASSED  
          sts_serial|   3|    100000|     100|0.74789208|  PASSED  
          sts_serial|   3|    100000|     100|0.88735895|  PASSED  
          sts_serial|   4|    100000|     100|0.21691795|  PASSED  
          sts_serial|   4|    100000|     100|0.67992567|  PASSED  
          sts_serial|   5|    100000|     100|0.72657859|  PASSED  
          sts_serial|   5|    100000|     100|0.68516675|  PASSED  
          sts_serial|   6|    100000|     100|0.90483992|  PASSED  
          sts_serial|   6|    100000|     100|0.32521860|  PASSED  
          sts_serial|   7|    100000|     100|0.62766123|  PASSED  
          sts_serial|   7|    100000|     100|0.50116862|  PASSED  
          sts_serial|   8|    100000|     100|0.29416113|  PASSED  
          sts_serial|   8|    100000|     100|0.40425176|  PASSED  
          sts_serial|   9|    100000|     100|0.03213837|  PASSED  
          sts_serial|   9|    100000|     100|0.11385194|  PASSED  
          sts_serial|  10|    100000|     100|0.65613907|  PASSED  
          sts_serial|  10|    100000|     100|0.87510784|  PASSED  
          sts_serial|  11|    100000|     100|0.29821858|  PASSED  
          sts_serial|  11|    100000|     100|0.76588877|  PASSED  
          sts_serial|  12|    100000|     100|0.40928140|  PASSED  
          sts_serial|  12|    100000|     100|0.89362037|  PASSED  
          sts_serial|  13|    100000|     100|0.45256983|  PASSED  
          sts_serial|  13|    100000|     100|0.89790655|  PASSED  
          sts_serial|  14|    100000|     100|0.65773129|  PASSED  
          sts_serial|  14|    100000|     100|0.54351124|  PASSED  
          sts_serial|  15|    100000|     100|0.99426501|  PASSED  
          sts_serial|  15|    100000|     100|0.67091570|  PASSED  
          sts_serial|  16|    100000|     100|0.52857378|  PASSED  
          sts_serial|  16|    100000|     100|0.71494701|  PASSED  
         rgb_bitdist|   1|    100000|     100|0.16657224|  PASSED  
         rgb_bitdist|   2|    100000|     100|0.74229787|  PASSED  
         rgb_bitdist|   3|    100000|     100|0.88661586|  PASSED  
         rgb_bitdist|   4|    100000|     100|0.99225805|  PASSED  
         rgb_bitdist|   5|    100000|     100|0.59138409|  PASSED  
         rgb_bitdist|   6|    100000|     100|0.32530543|  PASSED  
         rgb_bitdist|   7|    100000|     100|0.98816548|  PASSED  
         rgb_bitdist|   8|    100000|     100|0.65342997|  PASSED  
         rgb_bitdist|   9|    100000|     100|0.18960951|  PASSED  
         rgb_bitdist|  10|    100000|     100|0.97042579|  PASSED  
         rgb_bitdist|  11|    100000|     100|0.19509408|  PASSED  
         rgb_bitdist|  12|    100000|     100|0.22011246|  PASSED  
rgb_minimum_distance|   2|     10000|    1000|0.28733897|  PASSED  
rgb_minimum_distance|   3|     10000|    1000|0.73658618|  PASSED  
rgb_minimum_distance|   4|     10000|    1000|0.57957327|  PASSED  
rgb_minimum_distance|   5|     10000|    1000|0.01041015|  PASSED  
    rgb_permutations|   2|    100000|     100|0.80618540|  PASSED  
    rgb_permutations|   3|    100000|     100|0.07174022|  PASSED  
    rgb_permutations|   4|    100000|     100|0.81289201|  PASSED  
    rgb_permutations|   5|    100000|     100|0.26890929|  PASSED  
      rgb_lagged_sum|   0|   1000000|     100|0.49400784|  PASSED  
      rgb_lagged_sum|   1|   1000000|     100|0.99998605|   WEAK   
      rgb_lagged_sum|   2|   1000000|     100|0.63410000|  PASSED  
      rgb_lagged_sum|   3|   1000000|     100|0.50211127|  PASSED  
      rgb_lagged_sum|   4|   1000000|     100|0.42163937|  PASSED  
      rgb_lagged_sum|   5|   1000000|     100|0.25924354|  PASSED  
      rgb_lagged_sum|   6|   1000000|     100|0.77993855|  PASSED  
      rgb_lagged_sum|   7|   1000000|     100|0.83636974|  PASSED  
      rgb_lagged_sum|   8|   1000000|     100|0.41536528|  PASSED  
      rgb_lagged_sum|   9|   1000000|     100|0.48393822|  PASSED  
      rgb_lagged_sum|  10|   1000000|     100|0.52195022|  PASSED  
      rgb_lagged_sum|  11|   1000000|     100|0.41107896|  PASSED  
      rgb_lagged_sum|  12|   1000000|     100|0.74121775|  PASSED  
      rgb_lagged_sum|  13|   1000000|     100|0.79929440|  PASSED  
      rgb_lagged_sum|  14|   1000000|     100|0.89385721|  PASSED  
      rgb_lagged_sum|  15|   1000000|     100|0.98728503|  PASSED  
      rgb_lagged_sum|  16|   1000000|     100|0.24029250|  PASSED  
      rgb_lagged_sum|  17|   1000000|     100|0.80790810|  PASSED  
      rgb_lagged_sum|  18|   1000000|     100|0.12823577|  PASSED  
      rgb_lagged_sum|  19|   1000000|     100|0.43789590|  PASSED  
      rgb_lagged_sum|  20|   1000000|     100|0.08817515|  PASSED  
      rgb_lagged_sum|  21|   1000000|     100|0.79148422|  PASSED  
      rgb_lagged_sum|  22|   1000000|     100|0.29786110|  PASSED  
      rgb_lagged_sum|  23|   1000000|     100|0.83792002|  PASSED  
      rgb_lagged_sum|  24|   1000000|     100|0.74103376|  PASSED  
      rgb_lagged_sum|  25|   1000000|     100|0.48539421|  PASSED  
      rgb_lagged_sum|  26|   1000000|     100|0.99802355|   WEAK   
      rgb_lagged_sum|  27|   1000000|     100|0.57183856|  PASSED  
      rgb_lagged_sum|  28|   1000000|     100|0.35218827|  PASSED  
      rgb_lagged_sum|  29|   1000000|     100|0.51636503|  PASSED  
      rgb_lagged_sum|  30|   1000000|     100|0.40489879|  PASSED  
      rgb_lagged_sum|  31|   1000000|     100|0.75258328|  PASSED  
      rgb_lagged_sum|  32|   1000000|     100|0.16146386|  PASSED  
     rgb_kstest_test|   0|     10000|    1000|0.57143056|  PASSED  
     dab_bytedistrib|   0|  51200000|       1|0.27321565|  PASSED  
             dab_dct| 256|     50000|       1|0.10556727|  PASSED  
Preparing to run test 207.  ntuple = 0
        dab_filltree|  32|  15000000|       1|0.28157599|  PASSED  
        dab_filltree|  32|  15000000|       1|0.94369853|  PASSED  
Preparing to run test 208.  ntuple = 0
       dab_filltree2|   0|   5000000|       1|0.22918371|  PASSED  
       dab_filltree2|   1|   5000000|       1|0.85235396|  PASSED  
Preparing to run test 209.  ntuple = 0
        dab_monobit2|  12|  65000000|       1|0.81334865|  PASSED  

so looks decent I guess. The Intel RDRAND mode could be tested as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant