# CVE-2026-97937: ftrace: fork: Initialize function graph state before copy\_exec\_state()

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.8
- **CVSS:** 7.8 (v3.1, CNA) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- **CVSS metrics:** Attack vector: Local; Attack complexity: Low; Privileges required: Low; User interaction: None; Scope: Unchanged; Confidentiality impact: High; Integrity impact: High; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Not remotely exploitable (local or adjacent access needed)
- **EPSS:** 0.17% (percentile 3, 2026-11-26)
- **Published:** 2026-09-25T10:22:51.075Z
- **Modified:** 2026-10-19T10:17:44.750Z

## Who should check

- Anyone running Linux \>= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, \< 1fadebbbf31f65beba353fa9d1373bf183e03fed; \>= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, \< 08cacffeef8f64f1a222c93467ca84f24a46c953
- Anyone running Linux 7.2

## Description

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

ftrace: fork: Initialize function graph state before copy\_exec\_state()

dup\_task\_struct() copies the parent's task\_struct, including ret\_stack.
ftrace\_graph\_init\_task() clears the copied function graph state, but it
currently runs after copy\_exec\_state().

For non-CLONE\_VM forks, copy\_exec\_state() allocates a new task\_exec\_state.
If that allocation fails, copy\_process() reaches bad\_fork\_free and
free\_task() calls ftrace\_graph\_exit\_task(). Since the child still carries
the parent's ret\_stack pointer, the unwind frees the parent's active
function graph return stack. The parent subsequently accesses freed memory
from function\_graph\_enter\_regs().

KASAN reports:

\[   22.190920\] ==================================================================
\[   22.195899\] BUG: KASAN: slab-use-after-free in function\_graph\_enter\_regs+0xa76/0xb90
\[   22.200747\] Write of size 8 at addr ff110000054dc0a8 by task repro/1
\[   22.205134\]
\[   22.210770\] CPU: 0 UID: 0 PID: 1 Comm: repro Not tainted 7.2.0-07732-g9328b3b03bdc-dirty \#3 PREEMPT(lazy)
\[   22.212576\] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
\[   22.213750\] Call Trace:
\[   22.215271\]  \<TASK\>
\[   22.216242\]  ? ftrace\_stub\_direct\_tramp+0x10/0x10
\[   22.217774\]  dump\_stack\_lvl+0x4e/0x70
\[   22.220531\]  print\_report+0x157/0x4b4
\[   22.223202\]  ? fixup\_red\_left+0x9/0x30
\[   22.224407\]  ? complete\_report\_info+0x83/0x110
\[   22.226679\]  ? function\_graph\_enter\_regs+0xa76/0xb90
\[   22.228084\]  kasan\_report+0xce/0x100
\[   22.230109\]  ? function\_graph\_enter\_regs+0xa76/0xb90
\[   22.232860\]  ? stack\_trace\_save+0x4/0xd0
\[   22.234156\]  function\_graph\_enter\_regs+0xa76/0xb90
\[   22.236090\]  ? kasan\_save\_stack+0x30/0x50
\[   22.237752\]  ? \_\_pfx\_function\_graph\_enter\_regs+0x10/0x10
\[   22.238694\]  ? ring\_buffer\_lock\_reserve+0x345/0xf80
\[   22.239628\]  ? stack\_trace\_save+0x4/0xd0
\[   22.242121\]  ? stack\_trace\_save+0x4/0xd0
\[   22.243588\]  ftrace\_graph\_func+0xda/0x160
\[   22.245362\]  ? ftrace\_stub\_direct\_tramp+0x10/0x10
\[   22.246520\]  0xffffffffa0000095
\[   22.250528\]  ? stack\_trace\_save+0x9/0xd0
\[   22.251757\]  ? ring\_buffer\_unlock\_commit+0x11d/0x5c0
\[   22.253152\]  stack\_trace\_save+0x9/0xd0
\[   22.254264\]  kasan\_save\_stack+0x30/0x50
\[   22.273631\]  kasan\_save\_track+0x14/0x30
\[   22.276763\]  kasan\_save\_free\_info+0x3b/0x70
\[   22.278296\]  \_\_kasan\_slab\_free+0x43/0x70
\[   22.280157\]  kmem\_cache\_free+0xbf/0x3b0
\[   22.282963\]  ? ftrace\_stub\_direct\_tramp+0x10/0x10
\[   22.284001\]  free\_task+0xa2/0x160
\[   22.285699\]  ? ftrace\_stub\_direct\_tramp+0x10/0x10
\[   22.286752\]  copy\_process+0x2aae/0x7bc0

Initialize the child function graph state immediately after
dup\_task\_struct(), before the first fallible operation.

## Affected and fixed versions

- Linux: \>= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, \< 1fadebbbf31f65beba353fa9d1373bf183e03fed; \>= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, \< 08cacffeef8f64f1a222c93467ca84f24a46c953 (cvelist)
- Linux: 7.2 (cvelist)

## Mitigation

- Upgrade Linux to 08cacffeef8f64f1a222c93467ca84f24a46c953 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2026-97937. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2026-97937.md
Affected: Linux >= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, < 1fadebbbf31f65beba353fa9d1373bf183e03fed; >= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, < 08cacffeef8f64f1a222c93467ca84f24a46c953; Linux 7.2
Fixed in: Linux 1fadebbbf31f65beba353fa9d1373bf183e03fed, Linux 08cacffeef8f64f1a222c93467ca84f24a46c953

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.
```

## FAQ

### Is CVE-2026-97937 being exploited?

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

### How serious is CVE-2026-97937?

High: CVSS 7.8 (v3.1, scored by CNA). Not remotely exploitable (local or adjacent access needed).

### Which versions are affected by CVE-2026-97937?

Linux \>= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, \< 1fadebbbf31f65beba353fa9d1373bf183e03fed; \>= 6b1c66c9cca99bf00386481c7b2aa7394c26d8b8, \< 08cacffeef8f64f1a222c93467ca84f24a46c953; Linux 7.2.

### Is there a fix for CVE-2026-97937?

Yes. Fixed in Linux 1fadebbbf31f65beba353fa9d1373bf183e03fed, Linux 08cacffeef8f64f1a222c93467ca84f24a46c953. Upgrade Linux to 08cacffeef8f64f1a222c93467ca84f24a46c953 or later.

### How do I check if I'm affected by CVE-2026-97937?

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.

## References

- other: <https://git.kernel.org/stable/c/1fadebbbf31f65beba353fa9d1373bf183e03fed>
- other: <https://git.kernel.org/stable/c/08cacffeef8f64f1a222c93467ca84f24a46c953>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2026-97937>

HTML: <https://flawdb.com/CVE-2026-97937> · JSON: <https://flawdb.com/api/v1/entries/CVE-2026-97937>
