diff options
author | Matthias Wachs <wachs@net.in.tum.de> | 2013-10-29 16:41:02 +0000 |
---|---|---|
committer | Matthias Wachs <wachs@net.in.tum.de> | 2013-10-29 16:41:02 +0000 |
commit | 4f261de996daf0c2100eeb19cf3201f8e76930fc (patch) | |
tree | 7020963258efefab320613de0537d04dd4758d04 /src/include/gnunet_crypto_lib.h | |
parent | 07b82363864a0b477e0959512b73961406aef90f (diff) | |
download | gnunet-4f261de996daf0c2100eeb19cf3201f8e76930fc.tar.gz gnunet-4f261de996daf0c2100eeb19cf3201f8e76930fc.zip |
function to fill buffer with random values
Diffstat (limited to 'src/include/gnunet_crypto_lib.h')
-rw-r--r-- | src/include/gnunet_crypto_lib.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h index da4de4c87..980710b19 100644 --- a/src/include/gnunet_crypto_lib.h +++ b/src/include/gnunet_crypto_lib.h | |||
@@ -410,6 +410,17 @@ GNUNET_CRYPTO_crc32_n (const void *buf, size_t len); | |||
410 | 410 | ||
411 | /** | 411 | /** |
412 | * @ingroup crypto | 412 | * @ingroup crypto |
413 | * Fill block with a random values. | ||
414 | * | ||
415 | * @param mode desired quality of the random number | ||
416 | * @param buffer the buffer to fill | ||
417 | * @param length buffer length | ||
418 | */ | ||
419 | void | ||
420 | GNUNET_CRYPTO_random_block (enum GNUNET_CRYPTO_Quality mode, void *buffer, size_t length); | ||
421 | |||
422 | /** | ||
423 | * @ingroup crypto | ||
413 | * Produce a random value. | 424 | * Produce a random value. |
414 | * | 425 | * |
415 | * @param mode desired quality of the random number | 426 | * @param mode desired quality of the random number |