From: Kevin Wolf <kwolf@redhat.com>
To: Paolo Bonzini <pbonzini@redhat.com>
Cc: qemu-devel@nongnu.org, mreitz@redhat.com,
Li Qiang <liq3ea@gmail.com>, Keith Busch <keith.busch@intel.com>,
qemu-block@nongnu.org
Subject: Re: [Qemu-devel] [PATCH] nvme: fix out-of-bounds access to the CMB
Date: Thu, 22 Nov 2018 15:54:29 +0100 [thread overview]
Message-ID: <20181122145429.GD31879@linux.fritz.box> (raw)
In-Reply-To: <20181120184148.22501-1-pbonzini@redhat.com>
Am 20.11.2018 um 19:41 hat Paolo Bonzini geschrieben:
> Because the CMB BAR has a min_access_size of 2, if you read the last
> byte it will try to memcpy *2* bytes from n->cmbuf, causing an off-by-one
> error. This is CVE-2018-16847.
>
> Another way to fix this might be to register the CMB as a RAM memory
> region, which would also be more efficient. However, that might be a
> change for big-endian machines; I didn't think this through and I don't
> know how real hardware works. Add a basic testcase for the CMB in case
> somebody does this change later on.
>
> Cc: Keith Busch <keith.busch@intel.com>
> Cc: qemu-block@nongnu.org
> Reported-by: Li Qiang <liq3ea@gmail.com>
> Reviewed-by: Li Qiang <liq3ea@gmail.com>
> Tested-by: Li Qiang <liq3ea@gmail.com>
> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Thanks, applied to the block branch and reverted 5e3c0220d7.
Kevin
next prev parent reply other threads:[~2018-11-22 14:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-11-20 18:41 [Qemu-devel] [PATCH] nvme: fix out-of-bounds access to the CMB Paolo Bonzini
2018-11-20 21:20 ` Philippe Mathieu-Daudé
2018-11-22 6:37 ` no-reply
2018-11-22 14:54 ` Kevin Wolf [this message]
2018-11-22 17:01 ` Peter Maydell
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=20181122145429.GD31879@linux.fritz.box \
--to=kwolf@redhat.com \
--cc=keith.busch@intel.com \
--cc=liq3ea@gmail.com \
--cc=mreitz@redhat.com \
--cc=pbonzini@redhat.com \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.