]> git.baikalelectronics.ru Git - kernel.git/commit
random: set up the NUMA crng instances after the CRNG is fully initialized
authorTheodore Ts'o <tytso@mit.edu>
Wed, 11 Apr 2018 19:23:56 +0000 (15:23 -0400)
committerTheodore Ts'o <tytso@mit.edu>
Sat, 14 Apr 2018 15:59:19 +0000 (11:59 -0400)
commit5aa9a7b8c20692f4e8b30741682ea7ced11ce548
tree982e05c942d90c435fdb4dc0f303ae2c4cac22d6
parentfa72b520b15feaaf018ad331049a58654ddb0579
random: set up the NUMA crng instances after the CRNG is fully initialized

Until the primary_crng is fully initialized, don't initialize the NUMA
crng nodes.  Otherwise users of /dev/urandom on NUMA systems before
the CRNG is fully initialized can get very bad quality randomness.  Of
course everyone should move to getrandom(2) where this won't be an
issue, but there's a lot of legacy code out there.  This related to
CVE-2018-1108.

Reported-by: Jann Horn <jannh@google.com>
Fixes: eaef70dc9010 ("random: make /dev/urandom scalable for silly...")
Cc: stable@kernel.org # 4.8+
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
drivers/char/random.c