linux-crypto.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Remove PRNG from Linux Kernel
@ 2019-11-08 15:48 Frederick Gotham
  2019-11-09  5:03 ` Theodore Y. Ts'o
  0 siblings, 1 reply; 4+ messages in thread
From: Frederick Gotham @ 2019-11-08 15:48 UTC (permalink / raw)
  To: linux-crypto



Has anyone yet removed the random number generator entirely from the Linux 
kernel?

I'm currently working on an embedded x86_64 project, and I'm interfacing 
witht the TPM2 chip.

There cannot be any software-based psuedo-random number generators on my 
device, and so far I've removed three of them:

(1) The built-in PRNG inside OpenSSL
(2) The Intel RDRAND engine inside OpenSSL
(3) The simulator library that goes with the tpm2tss engine for OpenSSL 
(tcti-mssim)

The only software-based random-number generator left on my device is inside 
the Linux kernel (i.e. the one that feeds /dev/random).

I do realise that there are tools like 'rng-tools' for feeding a hardware 
generator into the entropy pool for "/dev/random" -- but this simply isn't 
good enough for my project.

I need to remove the PRNG from the Linux kernel and replace it with something 
that interfaces directly with the TPM2 chip.

Has this been done before?


^ permalink raw reply	[flat|nested] 4+ messages in thread
* Re: Remove PRNG from Linux Kernel
@ 2019-11-09 13:28 Thomas P. K. Healy
  0 siblings, 0 replies; 4+ messages in thread
From: Thomas P. K. Healy @ 2019-11-09 13:28 UTC (permalink / raw)
  To: linux-crypto

I've done performance testing, and I can generate 50 kilobytes of
random data in 6.9 seconds using the TMP2 hardware. This is adequate.

The boot-up state of my embedded device is very predictable, and so I
don't want any mathematical algorithms for psudeo-randomness present
on my device. I am cutting them all out.

I don't want to use the TPM2 to feed entropy into the Linux kernel's
PRNG. Instead I wish to remove the PRNG from the kernel and replace it
with a direct call to the TPM2 chip. Performance is not an issue here.

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

end of thread, other threads:[~2019-11-09 13:29 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-08 15:48 Remove PRNG from Linux Kernel Frederick Gotham
2019-11-09  5:03 ` Theodore Y. Ts'o
2019-11-09  6:36   ` Sandy Harris
2019-11-09 13:28 Thomas P. K. Healy

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