Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-30 Thread Qinglang Miao
在 2020/11/27 17:21, Steffen Maier 写道: On 11/26/20 4:12 PM, Benjamin Block wrote: On Thu, Nov 26, 2020 at 08:07:32PM +0800, Qinglang Miao wrote: 在 2020/11/26 17:42, Benjamin Block 写道: On Thu, Nov 26, 2020 at 09:13:53AM +0100, Cornelia Huck wrote: On Thu, 26 Nov 2020 09:27:41 +0800 Qinglang

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-27 Thread Steffen Maier
On 11/26/20 4:12 PM, Benjamin Block wrote: On Thu, Nov 26, 2020 at 08:07:32PM +0800, Qinglang Miao wrote: 在 2020/11/26 17:42, Benjamin Block 写道: On Thu, Nov 26, 2020 at 09:13:53AM +0100, Cornelia Huck wrote: On Thu, 26 Nov 2020 09:27:41 +0800 Qinglang Miao wrote: 在 2020/11/26 1:06, Benjamin

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-26 Thread Benjamin Block
On Thu, Nov 26, 2020 at 08:07:32PM +0800, Qinglang Miao wrote: > 在 2020/11/26 17:42, Benjamin Block 写道: > > On Thu, Nov 26, 2020 at 09:13:53AM +0100, Cornelia Huck wrote: > > > On Thu, 26 Nov 2020 09:27:41 +0800 > > > Qinglang Miao wrote: > > > > 在 2020/11/26 1:06, Benjamin Block 写道: > > > > > On

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-26 Thread Qinglang Miao
在 2020/11/26 17:42, Benjamin Block 写道: On Thu, Nov 26, 2020 at 09:13:53AM +0100, Cornelia Huck wrote: On Thu, 26 Nov 2020 09:27:41 +0800 Qinglang Miao wrote: 在 2020/11/26 1:06, Benjamin Block 写道: On Fri, Nov 20, 2020 at 03:48:54PM +0800, Qinglang Miao wrote: kfree(port) is called in put_

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-26 Thread Benjamin Block
On Thu, Nov 26, 2020 at 09:13:53AM +0100, Cornelia Huck wrote: > On Thu, 26 Nov 2020 09:27:41 +0800 > Qinglang Miao wrote: > > > 在 2020/11/26 1:06, Benjamin Block 写道: > > > On Fri, Nov 20, 2020 at 03:48:54PM +0800, Qinglang Miao wrote: > > >> kfree(port) is called in put_device(&port->dev) so t

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-26 Thread Cornelia Huck
On Thu, 26 Nov 2020 09:27:41 +0800 Qinglang Miao wrote: > 在 2020/11/26 1:06, Benjamin Block 写道: > > On Fri, Nov 20, 2020 at 03:48:54PM +0800, Qinglang Miao wrote: > >> kfree(port) is called in put_device(&port->dev) so that following > >> use would cause use-after-free bug. > >> > >> The former

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-25 Thread Qinglang Miao
在 2020/11/26 1:06, Benjamin Block 写道: On Fri, Nov 20, 2020 at 03:48:54PM +0800, Qinglang Miao wrote: kfree(port) is called in put_device(&port->dev) so that following use would cause use-after-free bug. The former put_device is redundant for device_unregister contains put_device already. So

Re: [PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-25 Thread Benjamin Block
On Fri, Nov 20, 2020 at 03:48:54PM +0800, Qinglang Miao wrote: > kfree(port) is called in put_device(&port->dev) so that following > use would cause use-after-free bug. > > The former put_device is redundant for device_unregister contains > put_device already. So just remove it to fix this. > > F

[PATCH] scsi: zfcp: fix use-after-free in zfcp_unit_remove

2020-11-19 Thread Qinglang Miao
kfree(port) is called in put_device(&port->dev) so that following use would cause use-after-free bug. The former put_device is redundant for device_unregister contains put_device already. So just remove it to fix this. Fixes: 86bdf218a717 ("[SCSI] zfcp: cleanup unit sysfs attribute usage") Report