Re: [2/2] ath9k: disable RNG by default

2016-09-28 Thread Kalle Valo
miaoqing pan wrote: > From: Miaoqing Pan > > ath9k RNG will dominates all the noise sources from the real HW > RNG, disable it by default. But we strongly recommand to enable > it if the system without HW RNG, especially on embedded systems. > > Signed-off-by: Miaoqing Pan > Acked-by: Stephan

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-11 Thread Jason Cooper
On Thu, Aug 11, 2016 at 10:54:11AM +0800, miaoq...@codeaurora.org wrote: > On 2016-08-10 21:24, Jason Cooper wrote: > >The fact is, barring userspace expectations of /dev/hwrng, hw_random is > >the appropriate place for it. It's not a devicetree blob, mac address, > >or pci config space. Which ar

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread miaoqing
Hi Jason, On 2016-08-10 21:24, Jason Cooper wrote: *gentle reminder: others are reading which may not be directly included in the conversation. Including the archives. Please avoid top posting. :) Thanks:) The fact is, barring userspace expectations of /dev/hwrng, hw_random is the approp

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Jason Cooper
Hi Miaoqing Pan, Stephen, *gentle reminder: others are reading which may not be directly included in the conversation. Including the archives. Please avoid top posting. :) On Wed, Aug 10, 2016 at 07:43:45AM +, Pan, Miaoqing wrote: > The problem with using the add_device_randomness is that w

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Stephan Mueller
Am Mittwoch, 10. August 2016, 07:15:49 CEST schrieb Pan, Miaoqing: Hi Miaoqing, > Hi Stephan, > > NIST SP 800-22-rev1a and NIST SP 800-90B are used together to evaluate the > amount of min entropy the source provides, and not to decide if the source > has passed the tests or failed. See > > htt

RE: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Pan, Miaoqing
Xu ; Matt Mackall ; miaoq...@codeaurora.org; Valo, Kalle ; linux-wirel...@vger.kernel.org; ath9k-devel ; linux-crypto@vger.kernel.org; ja...@lakedaemon.net; Sepehrdad, Pouyan Subject: Re: [PATCH 2/2] ath9k: disable RNG by default Am Mittwoch, 10. August 2016, 07:15:49 CEST schrieb Pan, Mia

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Stephan Mueller
Am Mittwoch, 10. August 2016, 02:35:04 CEST schrieb Pan, Miaoqing: Hi Miaoqing, > Hi Stephan, > > For those less perfect noise source, can't pass the FIPS test. > > static int update_kernel_random(int random_step, > unsigned char *buf, fips_ctx_t *fipsctx_in) > { > unsigned char

RE: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Pan, Miaoqing
, Miaoqing Cc: Herbert Xu ; Matt Mackall ; miaoq...@codeaurora.org; Valo, Kalle ; linux-wirel...@vger.kernel.org; ath9k-devel ; linux-crypto@vger.kernel.org; ja...@lakedaemon.net; Sepehrdad, Pouyan Subject: Re: [PATCH 2/2] ath9k: disable RNG by default Am Mittwoch, 10. August 2016, 07:15:49 CE

RE: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Pan, Miaoqing
Xu ; Matt Mackall ; miaoq...@codeaurora.org; Valo, Kalle ; linux-wirel...@vger.kernel.org; ath9k-devel ; linux-crypto@vger.kernel.org; ja...@lakedaemon.net; Sepehrdad, Pouyan Subject: Re: [PATCH 2/2] ath9k: disable RNG by default Am Mittwoch, 10. August 2016, 06:04:32 CEST schrieb Pan

RE: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Pan, Miaoqing
g; ja...@lakedaemon.net; Sepehrdad, Pouyan Subject: Re: [PATCH 2/2] ath9k: disable RNG by default Am Mittwoch, 10. August 2016, 02:35:04 CEST schrieb Pan, Miaoqing: Hi Miaoqing, > Hi Stephan, > > For those less perfect noise source, can't pass the FIPS test. > > static int

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Stephan Mueller
Am Mittwoch, 10. August 2016, 06:46:31 CEST schrieb Pan, Miaoqing: Hi Miaoqing, > Hi Stephan, > > Would you please provide a recent NIST document which asks the entropy > source to pass the NIST randomness tests ? See FIPS 140-2 IG 7.15 which explicitly references SP800-22. Ciao Stephan -- To

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Stephan Mueller
Am Mittwoch, 10. August 2016, 06:04:32 CEST schrieb Pan, Miaoqing: Hi Miaoqing, > Hi Stephan, > > FIPS RNG test is supposed to be run on the output of an RNG, and not on the > RNG entropy source. It is not surprising that the RNG input fails the > entropy tests from NIST. Check the following exa

RE: [PATCH 2/2] ath9k: disable RNG by default

2016-08-10 Thread Pan, Miaoqing
-wirel...@vger.kernel.org; ath9k-devel ; linux-crypto@vger.kernel.org; ja...@lakedaemon.net; Sepehrdad, Pouyan Subject: Re: [PATCH 2/2] ath9k: disable RNG by default Am Mittwoch, 10. August 2016, 06:46:31 CEST schrieb Pan, Miaoqing: Hi Miaoqing, > Hi Stephan, > > Would you please

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Pan, Miaoqing
H 2/2] ath9k: disable RNG by default Am Dienstag, 9. August 2016, 17:17:55 CEST schrieb Herbert Xu: Hi Herbert, > On Tue, Aug 09, 2016 at 11:02:58AM +0200, Stephan Mueller wrote: > > But shouldn't the default of the rngd then be adjusted a bit? > > Please elaborate. in rngd_linu

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Jason Cooper
Hi Henrique, On Tue, Aug 09, 2016 at 07:24:58AM -0300, Henrique de Moraes Holschuh wrote: > On Tue, 09 Aug 2016, Stephan Mueller wrote: > > RHEL 7 and Fedora do not adjust it. So, shall we consider those rng-tools > > then > > broken (at least in those large distros)? > > Might I humbly suggest

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Jason Cooper
On Tue, Aug 09, 2016 at 03:02:27PM +0800, miaoq...@codeaurora.org wrote: > From: Miaoqing Pan > > ath9k RNG will dominates all the noise sources from the real HW > RNG, disable it by default. But we strongly recommand to enable > it if the system without HW RNG, especially on embedded systems. >

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Henrique de Moraes Holschuh
On Tue, 09 Aug 2016, Stephan Mueller wrote: > RHEL 7 and Fedora do not adjust it. So, shall we consider those rng-tools > then > broken (at least in those large distros)? Might I humbly suggest that the kernel start providing some metatada about the quality of the random source that userspace ca

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Stephan Mueller
Am Dienstag, 9. August 2016, 17:56:57 CEST schrieb Herbert Xu: Hi Herbert, > On Tue, Aug 09, 2016 at 11:56:08AM +0200, Stephan Mueller wrote: > > Am Dienstag, 9. August 2016, 17:46:56 CEST schrieb Herbert Xu: > > > > Hi Herbert, > > > > > You're supposed to tweak the quality of the input. In a

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Herbert Xu
On Tue, Aug 09, 2016 at 11:56:08AM +0200, Stephan Mueller wrote: > Am Dienstag, 9. August 2016, 17:46:56 CEST schrieb Herbert Xu: > > Hi Herbert, > > > > You're supposed to tweak the quality of the input. In any case, > > How is that tweak supposed to happen? The rngd does not allow changing th

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Stephan Mueller
Am Dienstag, 9. August 2016, 17:46:56 CEST schrieb Herbert Xu: Hi Herbert, > > You're supposed to tweak the quality of the input. In any case, How is that tweak supposed to happen? The rngd does not allow changing the amount of read data relative to the assumed entropy. > this is not affected

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Herbert Xu
On Tue, Aug 09, 2016 at 11:37:39AM +0200, Stephan Mueller wrote: > Am Dienstag, 9. August 2016, 17:17:55 CEST schrieb Herbert Xu: > > Hi Herbert, > > > On Tue, Aug 09, 2016 at 11:02:58AM +0200, Stephan Mueller wrote: > > > But shouldn't the default of the rngd then be adjusted a bit? > > > > Ple

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Stephan Mueller
Am Dienstag, 9. August 2016, 17:17:55 CEST schrieb Herbert Xu: Hi Herbert, > On Tue, Aug 09, 2016 at 11:02:58AM +0200, Stephan Mueller wrote: > > But shouldn't the default of the rngd then be adjusted a bit? > > Please elaborate. in rngd_linux.c:random_add_entropy(void *buf, size_t size):

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Herbert Xu
On Tue, Aug 09, 2016 at 11:02:58AM +0200, Stephan Mueller wrote: > > But shouldn't the default of the rngd then be adjusted a bit? Please elaborate. Thanks, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt -- To unsubs

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Stephan Mueller
Am Dienstag, 9. August 2016, 16:58:58 CEST schrieb Herbert Xu: Hi Herbert, > On Tue, Aug 09, 2016 at 10:07:29AM +0200, Stephan Mueller wrote: > > Herbert, Matt, should such noise sources be added to the HW random > > framework? The thing is that the in-kernel HW random to input_pool link > > per

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Herbert Xu
On Tue, Aug 09, 2016 at 10:07:29AM +0200, Stephan Mueller wrote: > > Herbert, Matt, should such noise sources be added to the HW random framework? > The thing is that the in-kernel HW random to input_pool link per default uses > a more conservative entropy estimate than the user space rngd. I wo

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Stephan Mueller
Am Dienstag, 9. August 2016, 07:35:33 CEST schrieb Pan, Miaoqing: Hi Miaoqing, Herbert, Matt, > Hi Stephan, > > So your suggestion is to use HW Random framework ? Actually, which was > done by the commit 6301566e0b2d ("ath9k: export HW random number > generator"), but it was reverted, you can

RE: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Pan, Miaoqing
ad, Pouyan Subject: Re: [PATCH 2/2] ath9k: disable RNG by default Am Dienstag, 9. August 2016, 15:02:27 CEST schrieb miaoq...@codeaurora.org: Hi Miaoqing, > From: Miaoqing Pan > > ath9k RNG will dominates all the noise sources from the real HW RNG, > disable it by default. But we

Re: [PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread Stephan Mueller
Am Dienstag, 9. August 2016, 15:02:27 CEST schrieb miaoq...@codeaurora.org: Hi Miaoqing, > From: Miaoqing Pan > > ath9k RNG will dominates all the noise sources from the real HW > RNG, disable it by default. But we strongly recommand to enable > it if the system without HW RNG, especially on em

[PATCH 2/2] ath9k: disable RNG by default

2016-08-09 Thread miaoqing
From: Miaoqing Pan ath9k RNG will dominates all the noise sources from the real HW RNG, disable it by default. But we strongly recommand to enable it if the system without HW RNG, especially on embedded systems. Signed-off-by: Miaoqing Pan --- drivers/net/wireless/ath/ath9k/Kconfig | 2 +- 1 f