lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <VI1PR0702MB384026744E79BE0E82EABBDEE4600@VI1PR0702MB3840.eurprd07.prod.outlook.com>
Date:   Fri, 15 Feb 2019 05:40:51 +0000
From:   Bernd Edlinger <bernd.edlinger@...mail.de>
To:     Theodore Ts'o <tytso@....edu>, Arnd Bergmann <arnd@...db.de>,
        "Greg Kroah-Hartman" <gregkh@...uxfoundation.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] random: Make /dev/random wait for crng_ready

On 2/15/19 2:47 AM, Bernd Edlinger wrote:
>  	while (1) {
> -		n = extract_entropy_user(&blocking_pool, buf, nbytes);
> +		n = crng_ready()
> +			?  extract_entropy_user(&blocking_pool, buf, nbytes)
> +			: 0;

Aehm, the whitespace after ? does not align with :, didn't see that before.

I wonder if it would be better style to use
 if (crng_ready())
      n = extract...;
 else
      n = 0;


Bernd.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ