qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Eric Auger <eric.auger@redhat.com>,
	eric.auger.pro@gmail.com, qemu-devel@nongnu.org,
	qemu-arm@nongnu.org, mst@redhat.com, jean-philippe@linaro.org
Cc: qemu-stable@nongnu.org, mcascell@redhat.com, taoym@zju.edu.cn
Subject: Re: [PATCH for-8.1 v2] hw/virtio-iommu: Fix potential OOB access in virtio_iommu_handle_command()
Date: Mon, 17 Jul 2023 19:26:23 +0200	[thread overview]
Message-ID: <d28e1e4c-0c7c-e527-4f35-46ace2daa734@linaro.org> (raw)
In-Reply-To: <20230717162126.11693-1-eric.auger@redhat.com>

On 17/7/23 18:21, Eric Auger wrote:
> In the virtio_iommu_handle_command() when a PROBE request is handled,
> output_size takes a value greater than the tail size and on a subsequent
> iteration we can get a stack out-of-band access. Initialize the
> output_size on each iteration.

A backtrace would be helpful (or reproducer).

> The issue was found with ASAN. Credits to:
> Yiming Tao(Zhejiang University)
> Gaoning Pan(Zhejiang University)
> 
> Fixes: 1733eebb9e7 ("virtio-iommu: Implement RESV_MEM probe request")
> Signed-off-by: Eric Auger <eric.auger@redhat.com>
> Reported-by: Mauro Matteo Cascella <mcascell@redhat.com>

Did you mean:

Reported-by: Yiming Tao <taoym@zju.edu.cn>

?

> Cc: qemu-stable@nongnu.org
> 
> ---
> - added the Cc: qemu-stable@nongnu.org and copied 2 persons involved
>    in the reporting loop
> ---
>   hw/virtio/virtio-iommu.c | 4 +++-
>   1 file changed, 3 insertions(+), 1 deletion(-)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>



  reply	other threads:[~2023-07-17 17:26 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-17 16:21 [PATCH for-8.1 v2] hw/virtio-iommu: Fix potential OOB access in virtio_iommu_handle_command() Eric Auger
2023-07-17 17:26 ` Philippe Mathieu-Daudé [this message]
2023-07-17 17:32   ` Eric Auger

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d28e1e4c-0c7c-e527-4f35-46ace2daa734@linaro.org \
    --to=philmd@linaro.org \
    --cc=eric.auger.pro@gmail.com \
    --cc=eric.auger@redhat.com \
    --cc=jean-philippe@linaro.org \
    --cc=mcascell@redhat.com \
    --cc=mst@redhat.com \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-stable@nongnu.org \
    --cc=taoym@zju.edu.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).