Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1670313

Re: [PATCH] random: silence compiler warnings and fix race

From Theodore Ts'o <tytso@mit.edu>
Newsgroups linux.kernel
Subject Re: [PATCH] random: silence compiler warnings and fix race
Date 2017-06-20 08:10 +0200
Message-ID <tUkwq-4RO-11@gated-at.bofh.it> (permalink)
References <tSmj0-Qa-5@gated-at.bofh.it> <tSpgR-2GV-13@gated-at.bofh.it> <tUbWa-7E3-21@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Mon, Jun 19, 2017 at 10:57:18PM +0200, Jason A. Donenfeld wrote:
> 
> With rc6 already released and rc7 coming up, I'd really appreciate you
> stepping in here and either ACKing the above commit, or giving your
> two cents about it in case I need to roll something different.

I actually had set up an earlier version of your patch for on Saturday
while I was in Beijing.  (Like Linus, I'm attending the LinuxCon China
conference Monday and Tuesday.)  I had even created the signed tag,
but I didn't send the pull request to Linus because I was waiting to
see about how discussions over the locking strategy and the spammy log
messages on PowerPC was going to get resolved.

I've since respun the commit to reflect your newer patch (see the
random_for_linus_stable tag on random.git) and rebased the dev branch
on top of that.  Please take a look and comment.

The other open issue I want to resolve before sending a pull request
this week is whether we want to change the default for
CONFIG_WARN_UNSEEDED_RANDOM so that the answer is 'n'.  It *is* spammy
for PowerPC, because they aren't getting their CRNG initialized
quickly enough, so several userspace processes are getting
fork/exec'ed with an uninitialized CRNG.  That being said, it is a
valid warning because it means that the initial stack canary for the
first couple of PowerPC processes are being created without a fully
initialized CRNG, which may mean that an attacker might be able to
circumvent the stack canary on the first couple of processes.  So that
could potentially be a real security issue on Power.  OTOH, most Power
users aren't going to be able to do anything about the fact the stack
canaries of the system daemons started during early boot don't have
strong randomness, so perhaps we should disable the warning by
default.

Opinions?

						- Ted

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v5 00/13] Unseeded In-Kernel Randomness Fixes "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 13/13] random: warn when kernel uses unseeded randomness "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 06/13] iscsi: ensure RNG is seeded before use "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 05/13] crypto/rng: ensure that the RNG is ready before using "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 11/13] net/route: use get_random_int for random counter "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 10/13] net/neighbor: use get_random_u32 for 32-bit hash random "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 08/13] cifs: use get_random_u32 for 32-bit lock random "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 12/13] bluetooth/smp: ensure RNG is properly seeded before ECDH use "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 02/13] random: add synchronous API for the urandom pool "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 01/13] random: invalidate batched entropy after crng init "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
    Re: [PATCH v5 01/13] random: invalidate batched entropy after crng  init Sebastian Andrzej Siewior <sebastian@breakpoint.cc> - 2017-06-14 21:40 +0200
      Re: [PATCH v5 01/13] random: invalidate batched entropy after crng init "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-15 00:40 +0200
        Re: [PATCH v5 01/13] random: invalidate batched entropy after crng  init Sebastian Andrzej Siewior <sebastian@breakpoint.cc> - 2017-06-16 10:40 +0200
          Re: [PATCH v5 01/13] random: invalidate batched entropy after crng init "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-16 14:20 +0200
            Re: [PATCH v5 01/13] random: invalidate batched entropy after crng  init Sebastian Andrzej Siewior <sebastian@breakpoint.cc> - 2017-06-16 16:40 +0200
      [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-15 00:50 +0200
        Re: [PATCH] random: silence compiler warnings and fix race Sebastian Andrzej Siewior <bigeasy@linutronix.de> - 2017-06-16 16:40 +0200
          Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-17 02:40 +0200
            Re: [PATCH] random: silence compiler warnings and fix race Sebastian Andrzej Siewior <bigeasy@linutronix.de> - 2017-06-19 09:50 +0200
              Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-19 23:00 +0200
                Re: [PATCH] random: silence compiler warnings and fix race Sebastian Andrzej Siewior <bigeasy@linutronix.de> - 2017-06-20 08:50 +0200
        Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-19 23:00 +0200
          Re: [PATCH] random: silence compiler warnings and fix race Theodore Ts'o <tytso@mit.edu> - 2017-06-20 08:10 +0200
            Re: [kernel-hardening] Re: [PATCH] random: silence compiler warnings  and fix race Joel Stanley <joel@jms.id.au> - 2017-06-20 08:30 +0200
            Re: [kernel-hardening] Re: [PATCH] random: silence compiler warnings and fix race Michael Ellerman <mpe@ellerman.id.au> - 2017-06-20 09:10 +0200
            Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-20 10:20 +0200
              Re: [PATCH] random: silence compiler warnings and fix race Jeffrey Walton <noloader@gmail.com> - 2017-06-20 10:40 +0200
                Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-20 11:00 +0200
                Re: [PATCH] random: silence compiler warnings and fix race Jeffrey Walton <noloader@gmail.com> - 2017-06-20 11:50 +0200
                Re: [kernel-hardening] Re: [PATCH] random: silence compiler warnings  and fix race Sandy Harris <sandyinchina@gmail.com> - 2017-06-20 20:00 +0200
                Re: [kernel-hardening] Re: [PATCH] random: silence compiler warnings  and fix race Kees Cook <keescook@chromium.org> - 2017-06-20 20:20 +0200
                Re: [kernel-hardening] Re: [PATCH] random: silence compiler warnings  and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-20 22:10 +0200
                Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-20 11:50 +0200
                Re: [PATCH] random: silence compiler warnings and fix race Theodore Ts'o <tytso@mit.edu> - 2017-06-21 01:40 +0200
                Re: [PATCH] random: silence compiler warnings and fix race "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-21 02:00 +0200
                [PATCH] random: warn when kernel uses unseeded randomness "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-21 02:10 +0200
                Re: [PATCH] random: warn when kernel uses unseeded randomness Kees Cook <keescook@chromium.org> - 2017-06-21 02:20 +0200
                Re: [kernel-hardening] [PATCH] random: warn when kernel uses unseeded randomness Michael Ellerman <mpe@ellerman.id.au> - 2017-06-21 08:10 +0200
                Re: [kernel-hardening] [PATCH] random: warn when kernel uses  unseeded randomness Theodore Ts'o <tytso@mit.edu> - 2017-06-21 22:40 +0200
                Re: [kernel-hardening] [PATCH] random: warn when kernel uses unseeded randomness "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-22 02:10 +0200
                Re: [PATCH] random: silence compiler warnings and fix race Jeffrey Walton <noloader@gmail.com> - 2017-06-22 02:00 +0200
                Re: [PATCH] random: silence compiler warnings and fix race Theodore Ts'o <tytso@mit.edu> - 2017-06-20 12:00 +0200
  [PATCH v5 03/13] random: add get_random_{bytes,u32,u64,int,long,once}_wait family "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200
  [PATCH v5 04/13] security/keys: ensure RNG is seeded before use "Jason A. Donenfeld" <Jason@zx2c4.com> - 2017-06-08 01:30 +0200

csiph-web