From: "Jason A. Donenfeld" Subject: Re: [kernel-hardening] Re: [PATCH v4 06/13] iscsi: ensure RNG is seeded before use Date: Sat, 17 Jun 2017 02:41:39 +0200 Message-ID: References: <20170606174804.31124-1-Jason@zx2c4.com> <20170606174804.31124-7-Jason@zx2c4.com> <20170608024357.fhyyentj2qm7ti2q@thunk.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Cc: "Theodore Ts'o" , Linux Crypto Mailing List , LKML , kernel-hardening@lists.openwall.com, Greg Kroah-Hartman , David Miller , Eric Biggers , "Nicholas A. Bellinger" , Chris Leech , open-iscsi@googlegroups.com To: Lee Duncan Return-path: Received: from frisell.zx2c4.com ([192.95.5.64]:48359 "EHLO frisell.zx2c4.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752152AbdFQAlo (ORCPT ); Fri, 16 Jun 2017 20:41:44 -0400 In-Reply-To: Sender: linux-crypto-owner@vger.kernel.org List-ID: Hi Lee, On Fri, Jun 16, 2017 at 11:58 PM, Lee Duncan wrote: > It seems like what you are doing is basically "good", i.e. if there is > not enough random data, don't use it. But what happens in that case? The > authentication fails? How does the user know to wait and try again? The process just remains in interruptible (kill-able) sleep until there is enough entropy, so the process doesn't need to do anything. If the waiting is interrupted by a signal, it returns -ESYSRESTART, which follows the usual semantics of restartable syscalls. Jason