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-98551 Overview
CVE-2026-98551 is a Linux kernel vulnerability in the perf/core subsystem affecting arm64 systems with Branch Record Buffer Extension (BRBE). The flaw stems from perf_clear_branch_entry_bitfields() failing to clear the new_type and priv fields of struct perf_branch_entry. When arm_pmuv3.c allocates the per-CPU branch stack using kmalloc(), uninitialized slab memory reaches userspace through branch records. On the first pass over the buffer, raw kernel heap data is exposed; subsequent passes leak values from previous records.
Critical Impact
Local users on arm64 systems with BRBE enabled can obtain uninitialized kernel heap memory contents through perf branch stack sampling, potentially exposing sensitive kernel data.
Affected Products
- Linux kernel perf/core subsystem on arm64 platforms
- Systems with Branch Record Buffer Extension (BRBE) hardware
- Builds using arm_pmuv3.c with per-CPU branch stack allocated via kmalloc()
Discovery Timeline
- 2026-10-18 - CVE-2026-98551 published to NVD
- 2026-10-19 - Last updated in NVD database
Technical Details for CVE-2026-98551
Vulnerability Analysis
The Linux kernel's performance monitoring subsystem exposes branch tracking data to userspace through the perf interface. The function perf_clear_branch_entry_bitfields() was designed to zero out bitfield members of struct perf_branch_entry before population, while leaving from and to fields untouched because callers overwrite them directly.
The clearing routine must be maintained manually to track struct membership. Over time, two fields fell out of sync: new_type and priv were added to perf_branch_entry but never added to the clearing function. Only the BRBE path on arm64 writes these fields, and it does so conditionally. brbe_set_perf_entry_type() leaves new_type untouched for unrecognized branch types, and priv is skipped for source-only records.
Root Cause
The root cause is uninitialized memory use [CWE-908] combined with inconsistent struct field maintenance. Because arm_pmuv3.c allocates the per-CPU branch stack with kmalloc() rather than kzalloc(), the backing memory contains whatever data previously occupied those slab slots. Fields the BRBE code chooses not to write retain that stale content when records are delivered to userspace.
Attack Vector
A local, unprivileged user with permission to open perf events requesting branch stack sampling (PERF_SAMPLE_BRANCH_STACK) on an arm64 system with BRBE can read uninitialized kernel heap data. On first use of a slab-allocated branch stack, raw kmalloc() contents leak through new_type and priv bitfields. Afterward, residual values from previous branch records persist across samples.
The upstream fix replaces field-at-a-time clearing with a whole-struct assignment at each call site. The bitfields total exactly 64 bits with no padding, so an empty struct literal zeroes all unnamed members. perf_clear_branch_entry_bitfields() is removed, and perf_entry_from_brbe_regset() uses an empty literal since it fills from and to conditionally.
Detection Methods for CVE-2026-98551
Indicators of Compromise
- Unexpected processes opening perf_event_open() syscalls with PERF_SAMPLE_BRANCH_STACK set on arm64 hosts
- Unprivileged user accounts accessing performance counters on BRBE-capable systems
- Anomalous reads from /sys/bus/event_source/devices/armv8_pmuv3*/ on production servers
Detection Strategies
- Audit kernel version strings on arm64 fleets to identify systems running pre-patch builds with BRBE support compiled in
- Monitor perf_event_paranoid sysctl settings; values permitting unprivileged branch stack sampling expand exposure
- Review eBPF and perf tool usage telemetry to flag non-administrative users invoking branch tracing
Monitoring Recommendations
- Enable auditd rules for perf_event_open syscalls, capturing UID and sample type arguments
- Correlate perf activity with process lineage to identify unexpected branch sampling from user workloads
- Track kernel package versions through configuration management to confirm patch coverage across arm64 nodes
How to Mitigate CVE-2026-98551
Immediate Actions Required
- Apply the upstream kernel patches referenced in the stable tree commits as soon as distribution packages become available
- Inventory arm64 systems with BRBE hardware support to prioritize patching, since x86 and non-BRBE arm64 builds are unaffected
- Restrict unprivileged access to perf by setting kernel.perf_event_paranoid to 2 or 3 until patched kernels are deployed
Patch Information
The fix is distributed through the mainline and stable Linux kernel trees. Review the kernel commit 24b620729e53 and the kernel commit c7de8521947a for the exact code changes. The patch assigns the full perf_branch_entry structure at each population site and removes the now-unused perf_clear_branch_entry_bitfields() helper.
Workarounds
- Set kernel.perf_event_paranoid=3 via sysctl to disallow unprivileged perf usage on affected arm64 hosts
- Remove CAP_PERFMON and CAP_SYS_ADMIN capabilities from user-facing processes and containers
- Where feasible, disable BRBE in kernel configuration or at boot until a patched kernel is installed
# Restrict perf access until patched kernel is deployed
sudo sysctl -w kernel.perf_event_paranoid=3
echo 'kernel.perf_event_paranoid=3' | sudo tee /etc/sysctl.d/99-cve-2026-98551.conf
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

