[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r14264 - gnunet/src/util
From: |
gnunet |
Subject: |
[GNUnet-SVN] r14264 - gnunet/src/util |
Date: |
Wed, 26 Jan 2011 09:23:34 +0100 |
Author: grothoff
Date: 2011-01-26 09:23:34 +0100 (Wed, 26 Jan 2011)
New Revision: 14264
Modified:
gnunet/src/util/crypto_random.c
Log:
improve weak random generator
Modified: gnunet/src/util/crypto_random.c
===================================================================
--- gnunet/src/util/crypto_random.c 2011-01-25 22:58:30 UTC (rev 14263)
+++ gnunet/src/util/crypto_random.c 2011-01-26 08:23:34 UTC (rev 14264)
@@ -256,7 +256,6 @@
void __attribute__ ((constructor)) GNUNET_CRYPTO_random_init ()
{
- SRANDOM (time (NULL));
gcry_control (GCRYCTL_DISABLE_SECMEM, 0);
if (!gcry_check_version (GCRYPT_VERSION))
{
@@ -271,6 +270,7 @@
#endif
gcry_set_progress_handler (&entropy_generator, NULL);
atexit (&killfind);
+ SRANDOM (time (NULL) ^ GNUNET_CRYPTO_random_u32
(GNUNET_CRYPTO_QUALITY_NONCE, UINT32_MAX));
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r14264 - gnunet/src/util,
gnunet <=