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

bpf: Validate BTF repeated field counts before expansion

btf_parse_struct_metas() walks user-supplied BTF during BPF_BTF_LOAD,
and btf_repeat_fields() expands repeatable fields from array elements
into the fixed BTF_FIELDS_MAX scratch array used by btf_parse_fields().

The remaining-capacity check performs the expanded field count calculation
in u32. A malformed BTF can wrap that calculation, causing the check to
pass even when the expanded field count exceeds the scratch array
capacity. The following memcpy() can then write past the end of the
array.

Use checked addition and multiplication before copying repeated fields
and reject impossible counts.
Published: 2026-07-25
Score: 7.8 High
EPSS: < 1% Very Low
KEV: No
Impact: n/a
Action: n/a
AI Analysis

Impact

A malformed BTF descriptor can cause an overflow when calculating the number of expanded fields, which bypasses the capacity check performed by btf_parse_struct_metas(). The unchecked calculation allows the memcpy that copies repeated fields into a fixed‑size scratch array to write past the end of the array. This out‑of‑bounds write can corrupt kernel memory, potentially enabling an attacker who can load a BPF program to escape to higher privilege or crash the system.

Affected Systems

The flaw resides in the Linux kernel’s BPF runtime. Any platform running a Linux kernel that accepts user‑supplied BTF data via the BPF_BTF_LOAD interface is potentially affected, regardless of vendor. The patch is applied at the kernel source level and will be included in future kernel releases; affected systems must update to a version that includes the btf_repeat_fields fix.

Risk and Exploitability

The EPSS score is reported as less than 1%, indicating a low probability of exploitation at this time, and the vulnerability is not listed in the CISA KEV catalog. However, the vulnerability provides a direct memory corruption path that could allow local privilege escalation if an attacker can supply crafted BTF data. The attack vector is inferred to be local, requiring the ability to load a BPF program with the BTF_BTF_LOAD command. Successful exploitation could lead to kernel memory corruption, privilege escalation, or system crash.

Generated by OpenCVE AI on August 2, 2026 at 13:13 UTC.

Remediation

No vendor fix or workaround currently provided.

OpenCVE Recommended Actions

  • Upgrade the kernel to a version that includes the btf_repeat_fields fix
  • If immediate kernel upgrade is not possible, restrict the BPF_BTF_LOAD capability to trusted users or disable the BTF loading interface altogether
  • Apply package vendor updates through your distribution’s security tooling to ensure the patched kernel is installed
  • Monitor for any anomalous BPF activity and apply kernel hardening patches such as address space layout randomization (ASLR) and memlock limits

Generated by OpenCVE AI on August 2, 2026 at 13:13 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Debian DLA Debian DLA DLA-4724-1 linux-6.12 new package
History

Sat, 01 Aug 2026 02:30:00 +0000

Type Values Removed Values Added
Weaknesses CWE-680

Tue, 28 Jul 2026 00:15:00 +0000


Mon, 27 Jul 2026 05:15:00 +0000

Type Values Removed Values Added
Metrics cvssV3_1

{'score': 7.8, 'vector': 'CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H'}


Sun, 26 Jul 2026 02:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-680
CWE-787

Sat, 25 Jul 2026 09:30:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: bpf: Validate BTF repeated field counts before expansion btf_parse_struct_metas() walks user-supplied BTF during BPF_BTF_LOAD, and btf_repeat_fields() expands repeatable fields from array elements into the fixed BTF_FIELDS_MAX scratch array used by btf_parse_fields(). The remaining-capacity check performs the expanded field count calculation in u32. A malformed BTF can wrap that calculation, causing the check to pass even when the expanded field count exceeds the scratch array capacity. The following memcpy() can then write past the end of the array. Use checked addition and multiplication before copying repeated fields and reject impossible counts.
Title bpf: Validate BTF repeated field counts before expansion
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-08-05T12:41:03.295Z

Reserved: 2026-07-19T15:36:31.782Z

Link: CVE-2026-64354

cve-icon Vulnrichment

No data.

cve-icon NVD

Status : Awaiting Analysis

Published: 2026-07-25T10:17:17.810

Modified: 2026-08-11T15:01:50.637

Link: CVE-2026-64354

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-07-25T00:00:00Z

Links: CVE-2026-64354 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-08-02T13:15:03Z

Weaknesses