linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/5] Feed entropy pool via high-resolution clocksources
@ 2011-06-13 22:06 Jarod Wilson
  2011-06-13 22:06 ` [PATCH 1/5] random: add new clocksource entropy interface Jarod Wilson
                   ` (6 more replies)
  0 siblings, 7 replies; 46+ messages in thread
From: Jarod Wilson @ 2011-06-13 22:06 UTC (permalink / raw)
  To: linux-crypto
  Cc: Jarod Wilson, Matt Mackall, Venkatesh Pallipadi (Venki),
	Thomas Gleixner, Ingo Molnar, John Stultz, Herbert Xu,
	David S. Miller

Many server systems are seriously lacking in sources of entropy,
as we typically only feed the entropy pool by way of input layer
events, a few NIC driver interrupts and disk activity. A non-busy
server can easily become entropy-starved. We can mitigate this
somewhat by periodically mixing in entropy data based on the
delta between multiple high-resolution clocksource reads, per:

  https://www.osadl.org/Analysis-of-inherent-randomness-of-the-L.rtlws11-developers-okech.0.html

Additionally, NIST already approves of similar implementations, so
this should be usable in high-securtiy deployments requiring a
fair chunk of available entropy data for frequent use of /dev/random.

http://csrc.nist.gov/groups/STM/cmvp/documents/140-1/140sp/140sp750.pdf
(section 6.1 mentions a clock-based seed source).

Yes, thus far, I've only bothered with x86-based clocksources, since that
is what I can test most easily. If this patch series isn't deemed totally
insane, adding support for other clocksources should be trivial.

Also note that unless you explicitly build and load the clock-entropy
driver, there should be little or no change whatsoever to the way anything
behaves right now, its purely opt-in. There's probably room for some
improvement here, and I'm kind of outside my comfort area, but hey, it
seems to work pretty well here in my own testing, so here it is...

Jarod Wilson (5):
  random: add new clocksource entropy interface
  clocksource: add support for entropy-generation function
  hpet: wire up entropy generation function
  tsc: wire up entropy generation function
  misc: add clocksource-based entropy generation driver

 arch/x86/kernel/hpet.c       |   18 ++++++
 arch/x86/kernel/tsc.c        |   18 ++++++
 drivers/char/random.c        |   28 ++++++++++
 drivers/misc/Kconfig         |   14 +++++
 drivers/misc/Makefile        |    1 +
 drivers/misc/clock-entropy.c |  122 ++++++++++++++++++++++++++++++++++++++++++
 include/linux/clocksource.h  |    6 ++
 include/linux/random.h       |    1 +
 kernel/time/clocksource.c    |   33 +++++++++++
 9 files changed, 241 insertions(+), 0 deletions(-)
 create mode 100644 drivers/misc/clock-entropy.c

CC: Matt Mackall <mpm@selenic.com>
CC: "Venkatesh Pallipadi (Venki)" <venki@google.com>
CC: Thomas Gleixner <tglx@linutronix.de>
CC: Ingo Molnar <mingo@elte.hu>
CC: John Stultz <johnstul@us.ibm.com>
CC: Herbert Xu <herbert@gondor.apana.org.au>
CC: "David S. Miller" <davem@davemloft.net>

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

end of thread, other threads:[~2011-06-20  0:01 UTC | newest]

Thread overview: 46+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-06-13 22:06 [PATCH 0/5] Feed entropy pool via high-resolution clocksources Jarod Wilson
2011-06-13 22:06 ` [PATCH 1/5] random: add new clocksource entropy interface Jarod Wilson
2011-06-13 22:06 ` [PATCH 2/5] clocksource: add support for entropy-generation function Jarod Wilson
2011-06-17 20:52   ` Thomas Gleixner
2011-06-17 21:19     ` Jarod Wilson
2011-06-13 22:06 ` [PATCH 3/5] hpet: wire up entropy generation function Jarod Wilson
2011-06-13 22:06 ` [PATCH 4/5] tsc: " Jarod Wilson
2011-06-13 22:27   ` Venkatesh Pallipadi
2011-06-13 22:35     ` Jarod Wilson
2011-06-13 22:36     ` H. Peter Anvin
2011-06-13 23:10       ` Matt Mackall
2011-06-14 18:11         ` H. Peter Anvin
2011-06-14  0:39       ` Kent Borg
2011-06-14  1:47         ` H. Peter Anvin
2011-06-14 12:39           ` Kent Borg
2011-06-14 14:33             ` Matt Mackall
2011-06-14 17:48               ` Kent Borg
2011-06-14 18:00                 ` Matt Mackall
2011-06-14 20:04                   ` Kent Borg
2011-06-14 21:04                     ` Matt Mackall
2011-06-14 14:02           ` Jarod Wilson
2011-06-13 23:55     ` Kent Borg
2011-06-17 20:58     ` Thomas Gleixner
2011-06-13 22:06 ` [PATCH 5/5] misc: add clocksource-based entropy generation driver Jarod Wilson
2011-06-17 21:01   ` Thomas Gleixner
2011-06-13 22:38 ` [PATCH 0/5] Feed entropy pool via high-resolution clocksources john stultz
2011-06-14 14:25   ` Jarod Wilson
2011-06-13 23:15 ` Matt Mackall
2011-06-14 15:18   ` Jarod Wilson
2011-06-14 15:22     ` Jarod Wilson
2011-06-14 17:13     ` Matt Mackall
2011-06-14 20:17       ` Jarod Wilson
2011-06-14 21:45         ` Matt Mackall
2011-06-14 22:51           ` Jarod Wilson
2011-06-14 23:12             ` Matt Mackall
2011-06-15 14:49               ` Jarod Wilson
2011-06-15 20:06                 ` Matt Mackall
2011-06-17 18:51                   ` Jarod Wilson
2011-06-17 19:29                     ` Neil Horman
2011-06-17 20:46                       ` Matt Mackall
2011-06-17 19:48               ` hpas
2011-06-17 20:28                 ` Matt Mackall
2011-06-18 22:40                   ` H. Peter Anvin
2011-06-19 13:38                     ` Neil Horman
2011-06-19 15:07                       ` Herbert Xu
2011-06-20  0:01                         ` H. Peter Anvin

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).