Re: [Linux-kernel-mentees] [PATCH] block/floppy: Prevent kernel-infoleak in raw_cmd_copyout()

2020-07-29 Thread Peilin Ye
On Wed, Jul 29, 2020 at 12:18:42PM +0300, Denis Efremov wrote: > > > On 7/28/20 5:19 PM, Peilin Ye wrote: > > raw_cmd_copyout() is potentially copying uninitialized kernel stack memory > > since it is initializing `cmd` by assignment, which may cause the compiler > > to leave uninitialized holes

Re: [Linux-kernel-mentees] [PATCH] block/floppy: Prevent kernel-infoleak in raw_cmd_copyout()

2020-07-29 Thread Denis Efremov
On 7/28/20 5:19 PM, Peilin Ye wrote: > raw_cmd_copyout() is potentially copying uninitialized kernel stack memory > since it is initializing `cmd` by assignment, which may cause the compiler > to leave uninitialized holes in this structure. Fix it by using memcpy() > instead. > > Cc:

Re: [Linux-kernel-mentees] [PATCH] block/floppy: Prevent kernel-infoleak in raw_cmd_copyout()

2020-07-29 Thread Denis Efremov
Hi, On 7/28/20 5:19 PM, Peilin Ye wrote: > raw_cmd_copyout() is potentially copying uninitialized kernel stack memory > since it is initializing `cmd` by assignment, which may cause the compiler > to leave uninitialized holes in this structure. Fix it by using memcpy() > instead. > > Cc: