Skip to content
FlawDB
Sign in
Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

CVE-2025-37878

MEDIUM 5.5EPSS 13%

perf/core: Fix WARN_ON(!ctx) in __free_event() for partial init

Mitigation

  • Upgrade Linux to 6.14 or later.
  • Upgrade Linux to 6.14.5 or later.

Who should check

  • Anyone running Linux >= 7ef5aa081f989ecfecc1df02068a80aebbd3ec31, < 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e; >= 1209b0b29fd472e7dbd2b06544b019dd9f9b7e51, < cb56cd11feabf99e08bc18960700a53322ffcea7; >= c70ca298036c58a88686ff388d3d367e9d21acf0, < 0ba3a4ab76fd3367b9cb680cad70182c896c795c; 315a50c6b1c6ce191f19f3372935d8e2ed9b53a6; >= 6.13.12, < 6.14
  • Anyone running Linux >= 6.12.24, < 6.12.26; >= 6.14.3, < 6.14.5

Vulnerability facts

Affected
Linux >= 7ef5aa081f989ecfecc1df02068a80aebbd3ec31, < 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e; >= 1209b0b29fd472e7dbd2b06544b019dd9f9b7e51, < cb56cd11feabf99e08bc18960700a53322ffcea7; >= c70ca298036c58a88686ff388d3d367e9d21acf0, < 0ba3a4ab76fd3367b9cb680cad70182c896c795c; 315a50c6b1c6ce191f19f3372935d8e2ed9b53a6; >= 6.13.12, < 6.14; Linux >= 6.12.24, < 6.12.26; >= 6.14.3, < 6.14.5
Fixed in
Linux 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e, Linux 0ba3a4ab76fd3367b9cb680cad70182c896c795c, Linux 6.14, Linux 6.12.26, Linux 6.14.5
Exploited in the wild
Not in CISA KEV
Public exploit / PoC
None known
Remote exploitation
Not remotely exploitable (local or adjacent access needed)
CVSS
5.5 (v3.1, NVD)CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:HOpen in CVSS calculator
Show all 8 CVSS metrics
  • Attack vector: Local
  • Attack complexity: Low
  • Privileges required: Low
  • User interaction: None
  • Scope: Unchanged
  • Confidentiality impact: None
  • Integrity impact: None
  • Availability impact: High
EPSS
0.27% chance of exploitation in 30 days (percentile 13, 2026-11-26)
CWE
CWE-617
Published
Modified

Description

In the Linux kernel, the following vulnerability has been resolved: perf/core: Fix WARN_ON(!ctx) in __free_event() for partial init Move the get_ctx(child_ctx) call and the child_event->ctx assignment to occur immediately after the child event is allocated. Ensure that child_event->ctx is non-NULL before any subsequent error path within inherit_event calls free_event(), satisfying the assumptions of the cleanup code. Details: There's no clear Fixes tag, because this bug is a side-effect of multiple interacting commits over time (up to 15 years old), not a single regression. The code initially incremented refcount then assigned context immediately after the child_event was created. Later, an early validity check for child_event was added before the refcount/assignment. Even later, a WARN_ON_ONCE() cleanup check was added, assuming event->ctx is valid if the pmu_ctx is valid. The problem is that the WARN_ON_ONCE() could trigger after the initial check passed but before child_event->ctx was assigned, violating its precondition. The solution is to assign child_event->ctx right after its initial validation. This ensures the context exists for any subsequent checks or cleanup routines, resolving the WARN_ON_ONCE(). To resolve it, defer the refcount update and child_event->ctx assignment directly after child_event->pmu_ctx is set but before checking if the parent event is orphaned. The cleanup routine depends on event->pmu_ctx being non-NULL before it verifies event->ctx is non-NULL. This also maintains the author's original intent of passing in child_ctx to find_get_pmu_context before its refcount/assignment. [ mingo: Expanded the changelog from another email by Gabriel Shahrouzi. ]

Affected and fixed versions

Package / productAffectedFixedSource
Linux>= 7ef5aa081f989ecfecc1df02068a80aebbd3ec31, < 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e; >= 1209b0b29fd472e7dbd2b06544b019dd9f9b7e51, < cb56cd11feabf99e08bc18960700a53322ffcea7; >= c70ca298036c58a88686ff388d3d367e9d21acf0, < 0ba3a4ab76fd3367b9cb680cad70182c896c795c; 315a50c6b1c6ce191f19f3372935d8e2ed9b53a6; >= 6.13.12, < 6.14—cvelist
Linux>= 6.12.24, < 6.12.26; >= 6.14.3, < 6.14.5—cvelist

Check your systems with an agent

Paste this into Claude Code, Cursor or another coding agent. It only reads; it changes nothing.

Check whether anything I run is affected by CVE-2025-37878. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-37878.md
Affected: Linux >= 7ef5aa081f989ecfecc1df02068a80aebbd3ec31, < 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e; >= 1209b0b29fd472e7dbd2b06544b019dd9f9b7e51, < cb56cd11feabf99e08bc18960700a53322ffcea7; >= c70ca298036c58a88686ff388d3d367e9d21acf0, < 0ba3a4ab76fd3367b9cb680cad70182c896c795c; 315a50c6b1c6ce191f19f33729…
Fixed in: Linux 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e, Linux 0ba3a4ab76fd3367b9cb680cad70182c896c795c, Linux 6.14, Linux 6.12.26, Linux 6.14.5

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.

References

FAQ

Is CVE-2025-37878 being exploited?

There is no confirmed exploitation: CVE-2025-37878 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.27% chance of exploitation in the next 30 days (as of 2026-11-26).

How serious is CVE-2025-37878?

Medium: CVSS 5.5 (v3.1, scored by NVD). Not remotely exploitable (local or adjacent access needed).

Which versions are affected by CVE-2025-37878?

Linux >= 7ef5aa081f989ecfecc1df02068a80aebbd3ec31, < 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e; >= 1209b0b29fd472e7dbd2b06544b019dd9f9b7e51, < cb56cd11feabf99e08bc18960700a53322ffcea7; >= c70ca298036c58a88686ff388d3d367e9d21acf0, < 0ba3a4ab76fd3367b9cb680cad70182c896c795c; 315a50c6b1c6ce191f19f3372935d8e2ed9b53a6; >= 6.13.12, < 6.14; Linux >= 6.12.24, < 6.12.26; >= 6.14.3, < 6.14.5.

Is there a fix for CVE-2025-37878?

Yes. Fixed in Linux 90dc6c1e3b200812da8d0aa030e1b7fda8226d0e, Linux 0ba3a4ab76fd3367b9cb680cad70182c896c795c, Linux 6.14, Linux 6.12.26, Linux 6.14.5. Upgrade Linux to 6.14 or later. Upgrade Linux to 6.14.5 or later.

How do I check if I'm affected by CVE-2025-37878?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

Sponsors