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>] [day] [month] [year] [list]
Message-ID: <2025122409-CVE-2023-54097-3fb1@gregkh>
Date: Wed, 24 Dec 2025 14:06:54 +0100
From: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
To: linux-cve-announce@...r.kernel.org
Cc: Greg Kroah-Hartman <gregkh@...nel.org>
Subject: CVE-2023-54097: regulator: stm32-pwr: fix of_iomap leak

From: Greg Kroah-Hartman <gregkh@...nel.org>

Description
===========

In the Linux kernel, the following vulnerability has been resolved:

regulator: stm32-pwr: fix of_iomap leak

Smatch reports:
drivers/regulator/stm32-pwr.c:166 stm32_pwr_regulator_probe() warn:
'base' from of_iomap() not released on lines: 151,166.

In stm32_pwr_regulator_probe(), base is not released
when devm_kzalloc() fails to allocate memory or
devm_regulator_register() fails to register a new regulator device,
which may cause a leak.

To fix this issue, replace of_iomap() with
devm_platform_ioremap_resource(). devm_platform_ioremap_resource()
is a specialized function for platform devices.
It allows 'base' to be automatically released whether the probe
function succeeds or fails.

Besides, use IS_ERR(base) instead of !base
as the return value of devm_platform_ioremap_resource()
can either be a pointer to the remapped memory or
an ERR_PTR() encoded error code if the operation fails.

The Linux kernel CVE team has assigned CVE-2023-54097 to this issue.


Affected and fixed versions
===========================

	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 5.4.243 with commit 824683dbec234a01bd49a0589ee3323594a6f4cf
	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 5.10.180 with commit dfce9bb3517a78507cf96f9b83948d0b81338afa
	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 5.15.111 with commit ad6481f49fb2c703efa3a929643934f24b666d6a
	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 6.1.28 with commit f25994f7a9ad53eb756bc4869497c3ebe281ad5e
	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 6.2.15 with commit c091bb49b3233307c7af73dae888f0799752af3d
	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 6.3.2 with commit 0ad07e02be0d3f0d554653382ffe53ae4879378d
	Issue introduced in 5.2 with commit dc62f951a6a8490bcccc7b6de36cd85bd57be740 and fixed in 6.4 with commit c4a413e56d16a2ae84e6d8992f215c4dcc7fac20

Please see https://www.kernel.org for a full list of currently supported
kernel versions by the kernel community.

Unaffected versions might change over time as fixes are backported to
older supported kernel versions.  The official CVE entry at
	https://cve.org/CVERecord/?id=CVE-2023-54097
will be updated if fixes are backported, please check that for the most
up to date information about this issue.


Affected files
==============

The file(s) affected by this issue are:
	drivers/regulator/stm32-pwr.c


Mitigation
==========

The Linux kernel CVE team recommends that you update to the latest
stable kernel version for this, and many other bugfixes.  Individual
changes are never tested alone, but rather are part of a larger kernel
release.  Cherry-picking individual commits is not recommended or
supported by the Linux kernel community at all.  If however, updating to
the latest release is impossible, the individual changes to resolve this
issue can be found at these commits:
	https://git.kernel.org/stable/c/824683dbec234a01bd49a0589ee3323594a6f4cf
	https://git.kernel.org/stable/c/dfce9bb3517a78507cf96f9b83948d0b81338afa
	https://git.kernel.org/stable/c/ad6481f49fb2c703efa3a929643934f24b666d6a
	https://git.kernel.org/stable/c/f25994f7a9ad53eb756bc4869497c3ebe281ad5e
	https://git.kernel.org/stable/c/c091bb49b3233307c7af73dae888f0799752af3d
	https://git.kernel.org/stable/c/0ad07e02be0d3f0d554653382ffe53ae4879378d
	https://git.kernel.org/stable/c/c4a413e56d16a2ae84e6d8992f215c4dcc7fac20

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ