archive mirror
 help / color / mirror / Atom feed
From: Linus Torvalds <>
To: Kees Cook <>
Cc: tcharding <>, "Theodore Ts'o" <>,
	Steven Rostedt <>,
	Anna-Maria Gleixner <>,
	Linux Kernel Mailing List <>,
	"Jason A. Donenfeld" <>
Subject: Re: Hashed pointer issues
Date: Mon, 30 Apr 2018 20:07:52 +0000	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

On Mon, Apr 30, 2018 at 1:01 PM Linus Torvalds <> wrote:

> But if there are no actual users of get_random_bytes_arch(), maybe we can
> just remove the fallback to the non-arch code, and add that return value
> (and the __must_check()).

Hmm. It is exported, so maybe there is some crazy module out there.

Also, I have to admit that I hate the idea of people using that function
for a "fast random number generator". I think it's fine for this kind of
"initialize hashing state" thing, but I would hate for somebody to actually
use "get_random_bytes_arch()" as an actual source of random bytes.

Even when the "real" random number generator uses it, at least it washes
the result through chacha20 and has other sources or entropy mixed in too.

So let's rename it regardless. Both to see if any external module actually
uses that get_random_bytes_arch() function, and to discourage people to use
it as direct random data.

Maybe call it something like "get_seed_bytes_arch()" or something.

And maybe I'm just being silly.


  reply	other threads:[~2018-04-30 20:08 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-30 15:50 Anna-Maria Gleixner
2018-04-30 16:11 ` Kees Cook
2018-04-30 16:31   ` Linus Torvalds
2018-04-30 16:41     ` Steven Rostedt
2018-04-30 16:57       ` Linus Torvalds
2018-04-30 17:01         ` Linus Torvalds
2018-04-30 17:06           ` Randy Dunlap
2018-04-30 17:12             ` Linus Torvalds
2018-05-01  7:05               ` tcharding
2018-05-03  8:41             ` Geert Uytterhoeven
2018-04-30 18:38           ` Kees Cook
2018-04-30 19:00             ` Linus Torvalds
2018-04-30 19:16               ` Kees Cook
2018-04-30 20:01                 ` Linus Torvalds
2018-04-30 20:07                   ` Linus Torvalds [this message]
2018-04-30 21:23                 ` Tobin C. Harding

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \
    --subject='Re: Hashed pointer issues' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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