Re: [RESEND PATCH V3] binfmt_elf.c: use get_random_int() to fix entropy depleting

2012-11-14 Thread Kees Cook
On Wed, Nov 14, 2012 at 1:09 PM, Andrew Morton wrote: > On Tue, 6 Nov 2012 23:13:54 -0800 > Kees Cook wrote: > >> On Tue, Nov 6, 2012 at 11:02 PM, Jeff Liu wrote: >> > On 11/07/2012 02:21 PM, Kees Cook wrote: >> >> I still want to hear at least from Ted about this changes -- we would >> >> be po

Re: [RESEND PATCH V3] binfmt_elf.c: use get_random_int() to fix entropy depleting

2012-11-14 Thread Andrew Morton
On Tue, 6 Nov 2012 23:13:54 -0800 Kees Cook wrote: > On Tue, Nov 6, 2012 at 11:02 PM, Jeff Liu wrote: > > On 11/07/2012 02:21 PM, Kees Cook wrote: > >> I still want to hear at least from Ted about this changes -- we would > >> be potentially increasing the predictability of these bytes... > > >

Re: [RESEND PATCH V3] binfmt_elf.c: use get_random_int() to fix entropy depleting

2012-11-06 Thread Kees Cook
On Tue, Nov 6, 2012 at 11:02 PM, Jeff Liu wrote: > On 11/07/2012 02:21 PM, Kees Cook wrote: >> I still want to hear at least from Ted about this changes -- we would >> be potentially increasing the predictability of these bytes... > > We would not increasing that if this routine would be used for

Re: [RESEND PATCH V3] binfmt_elf.c: use get_random_int() to fix entropy depleting

2012-11-06 Thread Jeff Liu
On 11/07/2012 02:21 PM, Kees Cook wrote: > On Tue, Nov 6, 2012 at 10:11 PM, Jeff Liu wrote: >> Hello, >> >> This is the revised patch for fix entropy depleting. >> >> Changes: >> >> v3->v2: >> - Tweak code comments of random_stack_user(). >> - Remove redundant bits mask and shift upon the

Re: [RESEND PATCH V3] binfmt_elf.c: use get_random_int() to fix entropy depleting

2012-11-06 Thread Kees Cook
On Tue, Nov 6, 2012 at 10:11 PM, Jeff Liu wrote: > Hello, > > This is the revised patch for fix entropy depleting. > > Changes: > > v3->v2: > - Tweak code comments of random_stack_user(). > - Remove redundant bits mask and shift upon the random variable. > > v2->v1: > Fix random copy to c

[RESEND PATCH V3] binfmt_elf.c: use get_random_int() to fix entropy depleting

2012-11-06 Thread Jeff Liu
Hello, This is the revised patch for fix entropy depleting. Changes: v3->v2: - Tweak code comments of random_stack_user(). - Remove redundant bits mask and shift upon the random variable. v2->v1: Fix random copy to check up buffer length that are not 4-byte multiples. v2 can be found a