Re: [PATCH] libata: zpodd: Fix small read overflow in zpodd_get_mech_type()

2019-07-22 Thread Kees Cook
On Mon, Jul 22, 2019 at 10:40:40AM -0700, Nick Desaulniers wrote: > On Fri, Jul 19, 2019 at 8:41 PM Kees Cook wrote: > > > > Much like commit 18c9a99bce2a ("libata: zpodd: small read overflow in > > eject_tray()"), this fixes a cdb[] buffer length, this time in > > zpodd_get_mech_type(): > > > >

Re: [PATCH] libata: zpodd: Fix small read overflow in zpodd_get_mech_type()

2019-07-22 Thread Nick Desaulniers
On Fri, Jul 19, 2019 at 8:41 PM Kees Cook wrote: > > Much like commit 18c9a99bce2a ("libata: zpodd: small read overflow in > eject_tray()"), this fixes a cdb[] buffer length, this time in > zpodd_get_mech_type(): > > We read from the cdb[] buffer in ata_exec_internal_sg(). It has to be >

[PATCH] libata: zpodd: Fix small read overflow in zpodd_get_mech_type()

2019-07-19 Thread Kees Cook
Much like commit 18c9a99bce2a ("libata: zpodd: small read overflow in eject_tray()"), this fixes a cdb[] buffer length, this time in zpodd_get_mech_type(): We read from the cdb[] buffer in ata_exec_internal_sg(). It has to be ATAPI_CDB_LEN (16) bytes long, but this buffer is only 12 bytes. The