LWN.net Logo

Re: [PATCH] random, Add user configurable get_bytes_random()

From:  Theodore Ts'o <tytso-AT-mit.edu>
To:  Prarit Bhargava <prarit-AT-redhat.com>
Subject:  Re: [PATCH] random, Add user configurable get_bytes_random()
Date:  Thu, 5 Sep 2013 10:48:18 -0400
Message-ID:  <20130905144818.GA23661@thunk.org>
Cc:  linux-kernel-AT-vger.kernel.org
Archive-link:  Article, Thread

On Thu, Sep 05, 2013 at 08:18:44AM -0400, Prarit Bhargava wrote:
> The current code has two exported functions, get_bytes_random() and
> get_bytes_random_arch().  The first function only calls the entropy
> store to get random data, and the second only calls the arch specific
> hardware random number generator.
> 
> The problem is that no code is using the get_bytes_random_arch() and switching
> over will require a significant code change.  Even if the change is
> made it will be static forcing a recompile of code if/when a user has a
> system with a trusted random HW source.  A better thing to do is allow
> users to decide whether they trust their hardare random number generator.

I fail to see the benefit of just using the hardware random number
generator.  We are already mixing in the hardware random number
generator into the /dev/random pool, and so the only thing that using
only the HW source is to make the kernel more vulnerable to an attack
where the NSA leans on a few Intel employee and forces/bribes them to
make a change such that the last step in the RDRAND's AES whitening
step is changed to use a counter plus a AES key known by the NSA.

     		       	 	      - Ted


(Log in to post comments)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds