Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB
CVE-2026-97934 Overview
CVE-2026-97934 is a memory corruption vulnerability in the Linux kernel tracing subsystem. The flaw resides in the histogram trigger code path that handles the STACKTRACE generic field. When a user creates a histogram trigger keyed on STACKTRACE, the kernel misidentifies the field as a real stacktrace record and performs an unbounded memcpy using attacker-influenced data read from the event record. Triggering the condition requires local access to the tracefs interface, typically /sys/kernel/tracing, which is normally restricted to privileged users.
Critical Impact
Local users with access to tracefs can trigger a kernel general protection fault and panic, resulting in denial of service and potential memory corruption.
Affected Products
- Linux kernel (upstream) prior to the fix commit c27f8b68c058
- Linux stable branches receiving backports 7f711e62355b and 9e026a91fe79
- Distributions shipping affected kernel versions with tracing enabled
Discovery Timeline
- 2026-09-25 - CVE-2026-97934 published to NVD
- 2026-09-25 - Last updated in NVD database
Technical Details for CVE-2026-97934
Vulnerability Analysis
The Linux kernel tracing subsystem defines cpu, CPU, stacktrace, and STACKTRACE as generic fields with an offset and size of zero. The filter code matches these fields by name. The parse_field() function maps them onto their common_* equivalents for backward compatibility. Unlike the common_* names, the uppercase STACKTRACE placeholder is returned to the caller rather than NULL.
The downstream create_hist_field() function treats a non-NULL field as a promise that the record carries a stacktrace. It then selects the HIST_FIELD_FN_STACK handler. This handler reads the __data_loc word from offset 0 of the record, which actually contains common_type. The low 16 bits are interpreted as an offset into the record, and the value found there becomes the length of an unbounded memcpy.
Root Cause
The root cause is an inconsistency between parse_field() and create_hist_field(). The parser returns a placeholder field pointer for STACKTRACE instead of NULL, while the comment above the histogram field branch states the pointer should be NULL. This mismatch causes the histogram engine to interpret arbitrary event metadata as stacktrace layout information.
Attack Vector
A local user with write access to /sys/kernel/tracing can trigger the fault by attaching a histogram trigger keyed on STACKTRACE to a low-id event, then writing to trace_marker. The reproducer provided in the kernel commit log is:
cd /sys/kernel/tracing
echo 'hist:keys=STACKTRACE' > events/ftrace/print/trigger
echo hello > trace_marker
The resulting fault manifests as a general protection fault in memcpy+0xc/0x30 called from event_hist_trigger+0x2e7/0x12c0, followed by Kernel panic - not syncing: Fatal exception in interrupt. Because the length word is derived from kernel event data, the copy can target a non-canonical address and cause immediate panic, producing a reliable denial-of-service primitive.
Detection Methods for CVE-2026-97934
Indicators of Compromise
- Unexpected kernel panics referencing event_hist_trigger or memcpy in /IRQ context in system logs
- Writes to /sys/kernel/tracing/events/*/trigger containing the string hist:keys=STACKTRACE
- Processes with CAP_SYS_ADMIN enumerating or configuring tracefs histogram triggers outside normal observability workflows
Detection Strategies
- Audit kernel ring buffer and dmesg output for general protection fault entries referencing event_hist_trigger or rb_next
- Monitor file writes to tracefs trigger files using Linux audit rules on /sys/kernel/tracing/events
- Correlate tracefs configuration changes with the user and process context responsible for the change
Monitoring Recommendations
- Enable auditd watches on /sys/kernel/debug/tracing and /sys/kernel/tracing with -p w to capture trigger modifications
- Alert on kernel panics occurring shortly after tracing subsystem configuration changes
- Review which users and service accounts have been granted access to tracefs beyond root
How to Mitigate CVE-2026-97934
Immediate Actions Required
- Apply the upstream fix commit c27f8b68c058 or the corresponding stable backport for your kernel branch
- Restrict access to /sys/kernel/tracing and /sys/kernel/debug/tracing to trusted administrators only
- Review and remove non-essential grants of CAP_SYS_ADMIN that enable tracefs manipulation
Patch Information
The fix leaves the field pointer NULL for the STACKTRACE placeholder, matching the behavior of common_stacktrace and the intent documented in the surrounding comment. FILTER_CPU and FILTER_COMM are left unchanged because their create_hist_field() branches never dereference the field. Patches are available in the following commits: Kernel Git Commit 7f711e62355b, Kernel Git Commit 9e026a91fe79, and Kernel Git Commit c27f8b68c058.
Workarounds
- Unmount or remount tracefs with restrictive permissions where kernel tracing is not operationally required
- Disable histogram triggers in the kernel build configuration when feasible on hardened systems
- Use mandatory access control policies to deny write access to tracefs trigger files for non-root users
# Restrict tracefs access to root only
mount -o remount,mode=0700 /sys/kernel/tracing
# Add auditd rule to log trigger changes
auditctl -w /sys/kernel/tracing/events -p w -k tracefs_trigger
Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.
Sources: National Vulnerability Database, CISA KEV, Exploit-DB

