This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
static void silc_rng_exec_command(SilcRng rng, char *command);
static void silc_rng_get_hard_noise(SilcRng rng);
static void silc_rng_get_medium_noise(SilcRng rng);
static void silc_rng_exec_command(SilcRng rng, char *command);
static void silc_rng_get_hard_noise(SilcRng rng);
static void silc_rng_get_medium_noise(SilcRng rng);
noise from the environment. More soft noise is acquired after
64 bits of output and hard noise every 160 bits of output.
*/
noise from the environment. More soft noise is acquired after
64 bits of output and hard noise every 160 bits of output.
*/
/* This function adds the contents of the buffer as noise into random
pool. After adding the noise the pool is stirred. */
/* This function adds the contents of the buffer as noise into random
pool. After adding the noise the pool is stirred. */
- /* Get hard noise after 160 bits threshhold, zero the threshhold. */
- if (rng->threshhold >= 20) {
- rng->threshhold = 0;
+ /* Get hard noise after 160 bits threshold, zero the threshold. */
+ if (rng->threshold >= 20) {
+ rng->threshold = 0;
/* Initialize global RNG. If `rng' is provided it is set as the global
RNG object (it can be allocated by the application for example). */
/* Initialize global RNG. If `rng' is provided it is set as the global
RNG object (it can be allocated by the application for example). */
/* Return random byte as fast as possible. Reads from /dev/urandom if
available. If not then return from normal RNG (not so fast). */
/* Return random byte as fast as possible. Reads from /dev/urandom if
available. If not then return from normal RNG (not so fast). */