]> git.baikalelectronics.ru Git - kernel.git/commit
xen/scsifront: harden driver against malicious backend
authorJuergen Gross <jgross@suse.com>
Thu, 28 Apr 2022 07:53:23 +0000 (09:53 +0200)
committerJuergen Gross <jgross@suse.com>
Thu, 19 May 2022 12:02:49 +0000 (14:02 +0200)
commit94a5811f63afe902e159c548d0aca23bcf7df2ae
tree5eb2c927019c1208c8cccc97d9f2c2aeb7c2ad98
parent807d94c833a0abbce17556009a669643f90186bf
xen/scsifront: harden driver against malicious backend

Instead of relying on a well behaved PV scsi backend verify all meta
data received from the backend and avoid multiple reads of the same
data from the shared ring page.

In case any illegal data from the backend is detected switch the
PV device to a new "error" state and deactivate it for further use.

Use the "lateeoi" variant for the event channel in order to avoid
event storms blocking the guest.

Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Link: https://lore.kernel.org/r/20220428075323.12853-5-jgross@suse.com
Signed-off-by: Juergen Gross <jgross@suse.com>
drivers/scsi/xen-scsifront.c