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

perf/core: Fill branch entries with a single assignment

perf_clear_branch_entry_bitfields() clears the bitfields of struct
perf_branch_entry one by one and leaves from/to alone, since callers
overwrite those straight away. The list has to be kept in sync with the
struct by hand and has already fallen behind: new_type and priv were
added to perf_branch_entry and never added here.

Only BRBE writes those two, and neither for every record.
brbe_set_perf_entry_type() leaves new_type alone for a branch type it
does not recognise, and priv is not set for source-only records.
arm_pmuv3.c allocates the per-CPU branch stack with kmalloc(), so such a
record reaches userspace with whatever the slot held: uninitialised
kmalloc() data on the first pass over the buffer, the previous record's
values after that. Nothing under arch/x86/events/ writes either field,
so only arm64 is affected.

Assign the whole entry at each site instead. Everything not named is
then zero, and there is no list to keep in sync. The bitfields add up to
exactly 64 bits, so the struct has no padding to leave undefined.

perf_clear_branch_entry_bitfields() has no callers left, so remove it.
perf_entry_from_brbe_regset() assigns an empty literal instead, since it
fills from/to conditionally. PERF_BR_SPEC_NA is 0, so dropping the
explicit spec assignment changes nothing.
Published: 2026-10-18
Score: n/a
EPSS: n/a
KEV: No
Impact: Information Disclosure via uninitialised perf_branch_entry fields
Action: Immediate Patch
AI Analysis

Impact

The Linux kernel contains a flaw where the structure that holds branch event data contains two fields, new_type and priv, that are never initialised for a subset of records. When these values remain unset, the kernel exports the stale or uninitialised content of the structure to userspace through the perf subsystem. This can allow observers of perf data to read arbitrary kernel memory fragments that were previously stored in the slot, effectively leaking sensitive information. The weakness is a classic case of use of uninitialised variables, corresponding to CWE-457.

Affected Systems

All Linux kernel builds that include the perf core code before the recent commit that removes perf_clear_branch_entry_bitfields and replaces it with a full assignment. The advisory does not list specific kernel release numbers, but the issue affects configurations where branch event tracing is enabled, notably on arm64 architectures. Any distribution package that supplies an unpatched Linux image is potentially vulnerable.

Risk and Exploitability

The vulnerability does not appear in the CISA KEV catalog, indicating that no large‑scale exploitation campaigns have been observed. Based on the description, it is inferred that a local user who initiates a perf trace that includes branch events can trigger the flaw; the attacker can then extract the uninitialised data simply by reading the perf event buffer. Because the flaw is purely a data‑exposure issue without privilege escalation or denial of service impact, overall risk is moderate but the confidentiality compromise can be significant. The lack of a publicly disclosed exploit suggests low probability, yet patching remains prudent.

Generated by OpenCVE AI on October 19, 2026 at 00:00 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Upgrade the Linux kernel to a released version that incorporates the commit removing perf_clear_branch_entry_bitfields and assigns the entire perf_branch_entry structure at each site.
  • If a kernel upgrade is not currently possible, disable branch event tracing for all users by setting the appropriate boot, sysctl, or module parameters (e.g., reducing the branch trace buffer size to zero or removing the arm64 branch event configuration).
  • Configure the system to restrict access to perf event data to privileged users only, for example by setting /sys/fs/bpf or /sys/kernel/debug permission bits or by applying SELinux/AppArmor policies that limit perf data visibility.

Generated by OpenCVE AI on October 19, 2026 at 00:00 UTC.

Tracking

Sign in to view the affected projects.

Advisories

No advisories yet.

History

Mon, 19 Oct 2026 00:30:00 +0000

Type Values Removed Values Added
Weaknesses CWE-457

Sun, 18 Oct 2026 15:30:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: perf/core: Fill branch entries with a single assignment perf_clear_branch_entry_bitfields() clears the bitfields of struct perf_branch_entry one by one and leaves from/to alone, since callers overwrite those straight away. The list has to be kept in sync with the struct by hand and has already fallen behind: new_type and priv were added to perf_branch_entry and never added here. Only BRBE writes those two, and neither for every record. brbe_set_perf_entry_type() leaves new_type alone for a branch type it does not recognise, and priv is not set for source-only records. arm_pmuv3.c allocates the per-CPU branch stack with kmalloc(), so such a record reaches userspace with whatever the slot held: uninitialised kmalloc() data on the first pass over the buffer, the previous record's values after that. Nothing under arch/x86/events/ writes either field, so only arm64 is affected. Assign the whole entry at each site instead. Everything not named is then zero, and there is no list to keep in sync. The bitfields add up to exactly 64 bits, so the struct has no padding to leave undefined. perf_clear_branch_entry_bitfields() has no callers left, so remove it. perf_entry_from_brbe_regset() assigns an empty literal instead, since it fills from/to conditionally. PERF_BR_SPEC_NA is 0, so dropping the explicit spec assignment changes nothing.
Title perf/core: Fill branch entries with a single assignment
First Time appeared Linux
Linux linux Kernel
CPEs cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*
Vendors & Products Linux
Linux linux Kernel
References

Subscriptions

Linux Linux Kernel
cve-icon MITRE

Status: PUBLISHED

Assigner: Linux

Published:

Updated: 2026-10-18T15:18:19.008Z

Reserved: 2026-09-25T10:25:14.356Z

Link: CVE-2026-98551

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Received

Published: 2026-10-18T16:17:07.167

Modified: 2026-10-18T16:17:07.167

Link: CVE-2026-98551

cve-icon Redhat

No data.

cve-icon OpenCVE Enrichment

Updated: 2026-10-19T00:15:14Z

Weaknesses
  • CWE-457

    Use of Uninitialized Variable