[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2] sd: limit 'req.cmd' while using as an array
From: |
Peter Maydell |
Subject: |
Re: [Qemu-devel] [PATCH v2] sd: limit 'req.cmd' while using as an array index |
Date: |
Mon, 25 Jan 2016 11:51:44 +0000 |
On 20 January 2016 at 18:50, P J P <address@hidden> wrote:
> From: Prasad J Pandit <address@hidden>
>
> While processing standard SD commands, the 'req.cmd' value could
> lead to OOB read when used as an index into 'sd_cmd_type' or
> 'sd_cmd_class' arrays. Limit 'req.cmd' value to avoid such an
> access.
>
> Reported-by: Qinghao Tang <address@hidden>
> Signed-off-by: Prasad J Pandit <address@hidden>
> ---
> hw/sd/sd.c | 7 +++++--
> 1 file changed, 5 insertions(+), 2 deletions(-)
>
> Update as per review:
> -> https://lists.gnu.org/archive/html/qemu-devel/2016-01/msg03769.html
Reviewed-by: Peter Maydell <address@hidden>
thanks
-- PMM