From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Theodore Y. Ts'o" Subject: Re: [PATCH v8 2/3] fdt: add support for rng-seed Date: Wed, 21 Aug 2019 12:21:26 -0400 Message-ID: <20190821162126.GA2713@mit.edu> References: <20190819071602.139014-1-hsinyi@chromium.org> <20190819071602.139014-3-hsinyi@chromium.org> <20190819181349.GE10349@mit.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=m.gmane.org@lists.infradead.org To: Ard Biesheuvel Cc: Mark Rutland , Devicetree List , Yu Zhao , Kees Cook , Catalin Marinas , Stephen Boyd , Will Deacon , lkml , Mike Rapoport , Jun Yao , Miles Chen , Rob Herring , James Morse , Hsin-Yi Wang , Andrew Murray , Andrew Morton , Laura Abbott , Frank Rowand , "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" , Robin Murphy List-Id: devicetree@vger.kernel.org On Wed, Aug 21, 2019 at 09:39:28AM +0300, Ard Biesheuvel wrote: > > Whether to trust the firmware provided entropy is a policy decision, > and typically, we try to avoid dictating policy in the kernel, and > instead, we try to provide a sane default but give the user control > over it. > > So in this case, we should probably introduce > add_firmware_randomness() with a Kconfig/cmdline option pair to decide > whether it should be trusted or not (or reuse the one we have for > trusting RDRAND etc) I'd call it add_bootloader_randomness(), since we are trusting the *bootloader*; it's the bootloader which is vouching for the security / validity of the passed-in entropy. Furthermore, the bootloader on some architectures might be fetching directly from some secure element. And for that reason, I'd use a different Kconfig/cmdline option pair than the one used for trusting CPU-provided randomness. - Ted