Re: [dpdk-dev] [PATCH 1/3] vhost: fix split ring potential buffer overflow
From: Xia, Chenbo <hidden>
Date: 2021-03-31 07:49:06
From: Xia, Chenbo <hidden>
Date: 2021-03-31 07:49:06
-----Original Message-----
From: Liu, Yong <redacted>
Sent: Wednesday, March 31, 2021 2:50 PM
To: maxime.coquelin@redhat.com; Xia, Chenbo <redacted>
Cc: dev@dpdk.org; Liu, Yong <redacted>; stable@dpdk.org
Subject: [PATCH 1/3] vhost: fix split ring potential buffer overflow
In vhost datapath, descriptor's length are mostly used in two coherent
operations. First step is used for address translation, second step is
used for memory transaction from guest to host. But the iterval between
two steps will give a window for malicious guest, in which can change
descriptor length after vhost calcuated buffer size. Thus may lead to
buffer overflow in vhost side. This potential risk can be eliminated by
accessing the descriptor length once.
Fixes: 1be4ebb1c464 ("vhost: support indirect descriptor in mergeable Rx")
Cc: stable@dpdk.org
Signed-off-by: Marvin Liu <redacted>
Reviewed-by: Maxime Coquelin <redacted>
--
2.17.1Series applied to next-virtio/main, Thanks!