]> git.ipfire.org Git - thirdparty/qemu.git/commit
hw/virtio/virtio-crypto: Protect from DMA re-entrancy bugs
authorPhilippe Mathieu-Daudé <philmd@linaro.org>
Thu, 4 Apr 2024 18:56:41 +0000 (20:56 +0200)
committerMichael Tokarev <mjt@tls.msk.ru>
Wed, 10 Apr 2024 16:27:04 +0000 (19:27 +0300)
commit7aaf5f7778de4d75a169ab193f08857eb28db3a4
tree12021af7ac6a88b220a10e6b16a2aacdf6ea6aec
parente7c2df3fd748a20a8b7a316d186b3ac77551f159
hw/virtio/virtio-crypto: Protect from DMA re-entrancy bugs

Replace qemu_bh_new_guarded() by virtio_bh_new_guarded()
so the bus and device use the same guard. Otherwise the
DMA-reentrancy protection can be bypassed.

Fixes: CVE-2024-3446
Cc: qemu-stable@nongnu.org
Suggested-by: Alexander Bulekov <alxndr@bu.edu>
Reviewed-by: Gerd Hoffmann <kraxel@redhat.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Message-Id: <20240409105537.18308-5-philmd@linaro.org>
(cherry picked from commit f4729ec39ad97a42ceaa7b5697f84f440ea6e5dc)
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
hw/virtio/virtio-crypto.c