VYPR
Unrated severityNVD Advisory· Published Oct 15, 2025· Updated Apr 15, 2026

CVE-2025-39978

CVE-2025-39978

Description

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

octeontx2-pf: Fix potential use after free in otx2_tc_add_flow()

This code calls kfree_rcu(new_node, rcu) and then dereferences "new_node" and then dereferences it on the next line. Two lines later, we take a mutex so I don't think this is an RCU safe region. Re-order it to do the dereferences before queuing up the free.

AI Insight

LLM-synthesized narrative grounded in this CVE's description and references.

Use-after-free in Linux kernel octeontx2-pf driver: otx2_tc_add_flow() frees node then dereferences it, risking local privilege escalation.

Vulnerability

Details

In the Linux kernel's octeontx2-pf driver, the function otx2_tc_add_flow() contains a use-after-free bug. The code calls kfree_rcu(new_node, rcu) to schedule freeing of the new_node structure, but then immediately dereferences new_node on the next line. Because the RCU grace period may not have elapsed, the memory could be reused, leading to a use-after-free condition. The fix reorders the operations so that all dereferences occur before the kfree_rcu() call [1][2].

Exploitation

An attacker with local access to the system can trigger this vulnerability by adding a TC (traffic control) flow via the affected driver. No special privileges beyond the ability to interact with the network interface may be required, as the code path is reachable from user space through netlink or similar interfaces. The vulnerability does not require physical access or network-based exploitation.

Impact

Successful exploitation could allow an attacker to corrupt kernel memory, potentially leading to privilege escalation or a denial of service (system crash). The exact impact depends on the system configuration and the attacker's ability to control the freed memory.

Mitigation

The fix has been applied to the stable kernel trees as commits [1] and [2]. Users should update their Linux kernel to a version that includes these patches. No workaround is available; updating the kernel is the recommended mitigation.

AI Insight generated on May 19, 2026. Synthesized from this CVE's description and the cited reference URLs; citations are validated against the source bundle.

Affected products

2

Patches

5

Vulnerability mechanics

Generated on May 9, 2026. Inputs: CWE entries + fix-commit diffs from this CVE's patches. Citations validated against bundle.

References

5

News mentions

0

No linked articles in our index yet.