From cee8707b07952838e378ea7193af9eff83800b4e Mon Sep 17 00:00:00 2001 From: lloyd Date: Fri, 17 Feb 2012 13:16:17 +0000 Subject: Be more conservative about entropy estimates. In particular, instead of giving /dev/random, EGD, and CryptoAPI a full 8 bits per byte of entropy, estimate at 6 bits. In the proc walker, allow more files to be read, read more of any particular file, and count each bit for 1/10 as much as before. Reading more of the file seems especially valuable, as some files are quite random, whereas others are very static, and this should ensure we read more of the actually unpredictable inputs. Prefer /dev/random over /dev/urandom --- src/entropy/egd/es_egd.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/entropy/egd') diff --git a/src/entropy/egd/es_egd.cpp b/src/entropy/egd/es_egd.cpp index b2b629930..e0ebf9509 100644 --- a/src/entropy/egd/es_egd.cpp +++ b/src/entropy/egd/es_egd.cpp @@ -147,7 +147,7 @@ void EGD_EntropySource::poll(Entropy_Accumulator& accum) if(got) { - accum.add(&io_buffer[0], got, 8); + accum.add(&io_buffer[0], got, 6); break; } } -- cgit v1.2.3