[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <05f6a503-3639-b55d-3c22-1c6d1617093c@codeaurora.org>
Date: Thu, 30 Apr 2020 08:28:14 -0600
From: Jeffrey Hugo <jhugo@...eaurora.org>
To: Bhaumik Bhatt <bbhatt@...eaurora.org>, mani@...nel.org
Cc: linux-arm-msm@...r.kernel.org, linux-kernel@...r.kernel.org,
hemantk@...eaurora.org
Subject: Re: [PATCH v3 4/9] bus: mhi: core: Read transfer length from an event
properly
On 4/29/2020 2:52 PM, Bhaumik Bhatt wrote:
> From: Hemant Kumar <hemantk@...eaurora.org>
>
> When MHI Driver receives an EOT event, it reads xfer_len from the
> event in the last TRE. The value is under control of the MHI device
> and never validated by Host MHI driver. The value should never be
> larger than the real size of the buffer but a malicious device can
> set the value 0xFFFF as maximum. This causes driver to memory
> overflow (both read or write). Fix this issue by reading minimum of
> transfer length from event and the buffer length provided.
>
> Signed-off-by: Hemant Kumar <hemantk@...eaurora.org>
> Signed-off-by: Bhaumik Bhatt <bbhatt@...eaurora.org>
> ---
Reviewed-by: Jeffrey Hugo <jhugo@...eaurora.org>
--
Jeffrey Hugo
Qualcomm Technologies, Inc. is a member of the
Code Aurora Forum, a Linux Foundation Collaborative Project.
Powered by blists - more mailing lists