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] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZdsksQG/vMS0lWGq@shell.armlinux.org.uk>
Date: Sun, 25 Feb 2024 11:29:53 +0000
From: "Russell King (Oracle)" <linux@...linux.org.uk>
To: Duoming Zhou <duoming@....edu.cn>
Cc: linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	andrew@...n.ch, gregory.clement@...tlin.com,
	sebastian.hesselbarth@...il.com
Subject: Re: [PATCH] ARM: mvebu: Prevent null pointer dereference caused by
 kzalloc failure

On Sun, Feb 25, 2024 at 02:04:01PM +0800, Duoming Zhou wrote:
> The kzalloc() in i2c_quirk() will return null if the physical
> memory has run out. As a result, if we dereference the new_compat
> pointer, the null pointer dereference bug will happen.
> 
> This patch adds a check to avoid null pointer dereference.

Yet again another janitorial patch that is Way too focused on a single
issue, rather than analysing the code and proposing the best fix. :(

What if the two kstrdup() fail?

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ