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

of: unittest: fix use-after-free in testdrv_probe()

The function testdrv_probe() retrieves the device_node from the PCI
device, applies an overlay, and then immediately calls of_node_put(dn).
This releases the reference held by the PCI core, potentially freeing
the node if the reference count drops to zero. Later, the same freed
pointer 'dn' is passed to of_platform_default_populate(), leading to a
use-after-free.

The reference to pdev->dev.of_node is owned by the device model and
should not be released by the driver. Remove the erroneous of_node_put()
to prevent premature freeing.
Published: 2026-05-27
Score: n/a
EPSS: n/a
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

The vulnerability involves a use-after-free in the Linux kernel PCI device driver function testdrv_probe(). A reference to the OpenFirmware device node is prematurely released, freeing memory that is later accessed by of_platform_default_populate(). This flaw can corrupt memory, potentially allowing an attacker to corrupt kernel data structures, crash the system, or execute arbitrary code with kernel privileges.

Affected Systems

The affected product is the Linux kernel. No specific version range is provided in the advisory; the fix was applied in kernel commits starting with 07fd339b2c253205794bea5d9b4b7548a4546c56 and later. Linux, as the vendor, is the only identified product.

Risk and Exploitability

Exploitability is not quantified with an EPSS score and the vulnerability is not listed in the CISA KEV catalog. However, use-after-free flaws are generally high severity when an attacker can load the vulnerable driver or otherwise influence its execution. The lack of a CVSS score prevents precise quantification, but the nature of the flaw indicates a potentially high impact if exploited. Based on the description, it is inferred that an attacker would need local or elevated access to load the driver, after which the freed reference could lead to memory corruption or denial of service. The likely attack path is to trigger the driver via a device that uses testdrv, unless mitigated by disabling the driver or updating the kernel.

Generated by OpenCVE AI on May 27, 2026 at 18:43 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Apply a Linux kernel update that contains the commit 07fd339b2c253205794bea5d9b4b7548a4546c56 or later to remove the erroneous of_node_put call.
  • If a kernel upgrade is not immediately possible, prevent the vulnerable driver from loading by disabling or removing the testdrv module from the system using modprobe --disable or editing /etc/modprobe.d to blacklist it.
  • After disabling the module, monitor system logs for unexpected driver load attempts and verify that the driver is no longer present in the module list. If the system must run the driver, consider restricting its usage to trusted contexts and monitor for any memory corruption signs.

Generated by OpenCVE AI on May 27, 2026 at 18:43 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Wed, 27 May 2026 19:00:00 +0000

Type Values Removed Values Added
Weaknesses CWE-416

Wed, 27 May 2026 14:15:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: of: unittest: fix use-after-free in testdrv_probe() The function testdrv_probe() retrieves the device_node from the PCI device, applies an overlay, and then immediately calls of_node_put(dn). This releases the reference held by the PCI core, potentially freeing the node if the reference count drops to zero. Later, the same freed pointer 'dn' is passed to of_platform_default_populate(), leading to a use-after-free. The reference to pdev->dev.of_node is owned by the device model and should not be released by the driver. Remove the erroneous of_node_put() to prevent premature freeing.
Title of: unittest: fix use-after-free in testdrv_probe()
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References

Subscriptions

Linux Linux Kernel
cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published:

Updated: 2026-05-27T12:55:41.276Z

Reserved: 2026-05-13T15:03:33.091Z

Link: CVE-2026-45989

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Awaiting Analysis

Published: 2026-05-27T14:17:16.413

Modified: 2026-05-27T14:48:03.013

Link: CVE-2026-45989

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-05-27T21:30:34Z

Weaknesses