crypto: drbg - prepare for async seeding
authorStephan Mueller <smueller@chronox.de>
Mon, 25 May 2015 13:09:14 +0000 (15:09 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Wed, 27 May 2015 09:51:53 +0000 (17:51 +0800)
commit3d6a5f75d1340539dcdcec4609761fa4b836a1f2
treed19d3ccb4f4875c20dde086b8d7abe75b807a159
parent16b369a91d0dd80be214b7f7801fbc51875454cc
crypto: drbg - prepare for async seeding

In order to prepare for the addition of the asynchronous seeding call,
the invocation of seeding the DRBG is moved out into a helper function.

In addition, a block of memory is allocated during initialization time
that will be used as a scratchpad for obtaining entropy. That scratchpad
is used for the initial seeding operation as well as by the
asynchronous seeding call. The memory must be zeroized every time the
DRBG seeding call succeeds to avoid entropy data lingering in memory.

CC: Andreas Steffen <andreas.steffen@strongswan.org>
CC: Theodore Ts'o <tytso@mit.edu>
CC: Sandy Harris <sandyinchina@gmail.com>
Signed-off-by: Stephan Mueller <smueller@chronox.de>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
crypto/drbg.c
include/crypto/drbg.h
This page took 0.025496 seconds and 5 git commands to generate.