lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <478ad5a2-88b7-4069-aa9b-52084ffeda67@t-argos.ru>
Date: Thu, 11 Apr 2024 14:24:58 +0300
From: Aleksandr Mishin <amishin@...rgos.ru>
To: Konrad Dybcio <konrad.dybcio@...aro.org>, Christian Marangi
	<ansuelsmth@...il.com>
CC: Amit Kucheria <amitk@...nel.org>, Thara Gopinath
	<thara.gopinath@...il.com>, Bjorn Andersson <andersson@...nel.org>, "Rafael
 J. Wysocki" <rafael@...nel.org>, Daniel Lezcano <daniel.lezcano@...aro.org>,
	Zhang Rui <rui.zhang@...el.com>, Lukasz Luba <lukasz.luba@....com>,
	<linux-pm@...r.kernel.org>, <linux-arm-msm@...r.kernel.org>,
	<linux-kernel@...r.kernel.org>, <lvc-project@...uxtesting.org>
Subject: Re: [PATCH] drivers: thermal: tsens: Fix null pointer dereference



On 09.04.2024 12:52, Konrad Dybcio wrote:
> 
> 
> On 4/5/24 11:07, Aleksandr Mishin wrote:
>> compute_intercept_slope() is called from calibrate_8960() (in 
>> tsens-8960.c)
>> as compute_intercept_slope(priv, p1, NULL, ONE_PT_CALIB) which lead to 
>> null
>> pointer dereference (if DEBUG or DYNAMIC_DEBUG set).
>> Fix this bug by adding null pointer check.
>>
>> Found by Linux Verification Center (linuxtesting.org) with SVACE.
>>
>> Fixes: dfc1193d4dbd ("thermal/drivers/tsens: Replace custom 8960 apis 
>> with generic apis")
>> Signed-off-by: Aleksandr Mishin <amishin@...rgos.ru>
>> ---
> 
> Maybe we can replace p2[i] with p2 ? p2[i] : 0

Your solution look better for me. Thanks. I'll offer v2 patch

> 
> Konrad

-- 
Kind regards
Aleksandr

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ