1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-15 18:17:32 -05:00

Windows PuTTYgen: bound entropy input by PRNG state size.

Although I've reinstated the tedious manual mouse input, I can at
least reduce the amount of it that the user is required to provide:
the new PRNG has a hard limit on the size of its seed, so once we've
generated enough entropy to fill that up, there's no point in
collecting more, even if we're generating a particularly large key.
This commit is contained in:
Simon Tatham
2019-02-10 13:43:14 +00:00
parent 4d288dc3e9
commit 22131a51fa
5 changed files with 21 additions and 0 deletions

1
ssh.h
View File

@ -902,6 +902,7 @@ void prng_seed_begin(prng *p);
void prng_seed_finish(prng *p);
void prng_read(prng *p, void *vout, size_t size);
void prng_add_entropy(prng *p, unsigned source_id, ptrlen data);
size_t prng_seed_bits(prng *p);
/* This function must be implemented by the platform, and returns a
* timer in milliseconds that the PRNG can use to know whether it's