linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] crypto: drbg - revamp locking
@ 2015-04-17 12:53 Stephan Mueller
  2015-04-17 12:54 ` [PATCH 1/4] cryoto: drbg - clear all temporary memory Stephan Mueller
                   ` (3 more replies)
  0 siblings, 4 replies; 16+ messages in thread
From: Stephan Mueller @ 2015-04-17 12:53 UTC (permalink / raw)
  To: herbert; +Cc: linux-crypto

Hi,

the current implementation of the DRBG generates a shadow copy of its
DRBG state for each incoming request. The idea is that only a short
term lock is needed to spawn the shadow copy. The drawback is that
if multiple parallel requests come in, the generated DRBG shadow
states only differ by a high-resolution timer that was mixed in during
the shadow state generation.

This patch now removes this shadow state and introduces a mutex
to serialize all requests to one DRBG instance.

The patch was fully CAVS tested and demonstrates that the DRBG still
complies with the standard.

Stephan Mueller (4):
  cryoto: drbg - clear all temporary memory
  crypto: drbg - do not create shadow copy
  crypto: drbg - replace spinlock with mutex
  crypto: drbg - leave cipher handles operational

 crypto/drbg.c         | 154 +++++++++-----------------------------------------
 include/crypto/drbg.h |   4 +-
 2 files changed, 30 insertions(+), 128 deletions(-)

-- 
2.1.0

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2015-04-20  0:51 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-04-17 12:53 [PATCH 0/4] crypto: drbg - revamp locking Stephan Mueller
2015-04-17 12:54 ` [PATCH 1/4] cryoto: drbg - clear all temporary memory Stephan Mueller
2015-04-18 10:59   ` Herbert Xu
2015-04-17 12:54 ` [PATCH 2/4] crypto: drbg - do not create shadow copy Stephan Mueller
2015-04-18 10:49   ` Herbert Xu
2015-04-18 12:51     ` Stephan Mueller
2015-04-17 12:55 ` [PATCH 3/4] crypto: drbg - replace spinlock with mutex Stephan Mueller
2015-04-18 10:55   ` Herbert Xu
2015-04-18 11:35     ` Stephan Mueller
2015-04-19  5:48       ` Herbert Xu
2015-04-19 15:37         ` Stephan Mueller
2015-04-20  0:27           ` Herbert Xu
2015-04-20  0:45             ` Stephan Mueller
2015-04-20  0:48               ` Herbert Xu
2015-04-20  0:51                 ` Stephan Mueller
2015-04-17 12:56 ` [PATCH 4/4] crypto: drbg - leave cipher handles operational Stephan Mueller

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).