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

bpf: tcp: fix double sock release on batch realloc

bpf_iter_tcp_batch() releases the current batch via
bpf_iter_tcp_put_batch(), which drops the socket refs and rewrites
each slot with the socket cookie, then grows the batch. cur_sk/end_sk
are kept for bpf_iter_tcp_resume(), but on realloc failure the function
returns ERR_PTR() before resume runs, leaving cur_sk < end_sk over
slots that now hold cookies rather than sock pointers.
bpf_iter_tcp_seq_stop() then calls bpf_iter_tcp_put_batch() again and
dereferences a cookie as a struct sock.

Empty the batch on the failure path so stop() does not release it
again. The sockets were already freed by the first
bpf_iter_tcp_put_batch(), so nothing leaks, and a later read() rescans
the bucket from the start instead of skipping it. The sibling
GFP_NOWAIT failure path still holds real socket references and is left
for stop() to release.

BUG: KASAN: null-ptr-deref in __sock_gen_cookie
Read of size 8 at addr 0000000000000059 by task exploit
...
__sock_gen_cookie (net/core/sock_diag.c:28)
bpf_iter_tcp_put_batch (net/ipv4/tcp_ipv4.c:2918)
bpf_iter_tcp_seq_stop (net/ipv4/tcp_ipv4.c:3270)
bpf_seq_read (kernel/bpf/bpf_iter.c:205)
vfs_read (fs/read_write.c:572)
ksys_read (fs/read_write.c:716)
do_syscall_64
entry_SYSCALL_64_after_hwframe
Kernel panic - not syncing: Fatal exception
Published: 2026-08-05
Score: 7.8 High
EPSS: < 1% Very Low
KEV: No
Impact: Kernel Panic (Denial of Service)
Action: Patch Kernel
AI Analysis

Impact

A flaw in the Linux kernel’s BPF TCP iterator leads to a double release of socket references when a batch reallocation fails, causing a null‑pointer dereference during cookie processing. The exploit appears to result in a kernel panic, abruptly halting the system and denying availability to all processes. The vulnerability is a classic use‑after‑free (CWE‑416) combined with a duplicate release of resources (CWE‑825).

Affected Systems

All Linux kernel builds that predate the commit that fixes the double‑release logic are affected. No specific version numbers are provided, so any kernel older than the patch can potentially be vulnerable; administrators should verify the running kernel against vendor release notes for the update.

Risk and Exploitability

The CVSS score of 7.8 indicates high severity, while the EPSS score of less than 1% and absence from the CISA KEV catalog suggest low likelihood of widespread exploitation. Based on the description, it is inferred that an attacker with privileges to load or modify eBPF programs could trigger the vulnerable path, leading to a kernel crash. The attack requires that a BPF program exercise the TCP iterator’s batch reallocation, implying that exploitation is limited to environments where such programs are allowed.

Generated by OpenCVE AI on October 20, 2026 at 13:35 UTC.

Remediation

No solution or workaround provided in the CVE record.

OpenCVE Recommended Actions

  • Apply a kernel update that contains the bpf_iter_tcp_batch double‑release fix.
  • If an immediate upgrade is not possible, restrict or redesign eBPF programs that use the TCP iterator APIs to avoid batch traversal logic that may trigger reallocation failures.
  • Deploy kernel crash monitoring and review system logs for evidence of panics related to eBPF activity.
  • Continue to monitor vendor advisories and apply subsequent kernel updates as they become available.

Generated by OpenCVE AI on October 20, 2026 at 13:35 UTC.

Tracking

Sign in to view the affected projects.

Advisories
Source ID Title
Ubuntu USN Ubuntu USN USN-8887-1 Linux kernel vulnerabilities
Ubuntu USN Ubuntu USN USN-8888-1 Linux kernel (Azure) vulnerabilities
Ubuntu USN Ubuntu USN USN-8889-1 Linux kernel (OEM) vulnerabilities
Ubuntu USN Ubuntu USN USN-8887-2 Linux kernel (AWS) vulnerabilities
Ubuntu USN Ubuntu USN USN-8888-2 Linux kernel (Azure) vulnerabilities
Ubuntu USN Ubuntu USN USN-8887-3 Linux kernel vulnerabilities
History

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

Type Values Removed Values Added
Weaknesses CWE-416
Metrics ssvc

{'options': {'Automatable': 'no', 'Exploitation': 'none', 'Technical Impact': 'total'}, 'version': '2.0.3'}


Wed, 19 Aug 2026 16:45:00 +0000


Sat, 08 Aug 2026 15:15:00 +0000

Type Values Removed Values Added
Metrics cvssV3_1

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

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'}


Fri, 07 Aug 2026 02:30:00 +0000

Type Values Removed Values Added
Weaknesses CWE-416

Fri, 07 Aug 2026 00:15:00 +0000

Type Values Removed Values Added
Weaknesses CWE-825
References
Metrics threat_severity

None

cvssV3_1

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

threat_severity

Moderate


Wed, 05 Aug 2026 09:45:00 +0000

Type Values Removed Values Added
Weaknesses CWE-416

Wed, 05 Aug 2026 08:15:00 +0000

Type Values Removed Values Added
Description In the Linux kernel, the following vulnerability has been resolved: bpf: tcp: fix double sock release on batch realloc bpf_iter_tcp_batch() releases the current batch via bpf_iter_tcp_put_batch(), which drops the socket refs and rewrites each slot with the socket cookie, then grows the batch. cur_sk/end_sk are kept for bpf_iter_tcp_resume(), but on realloc failure the function returns ERR_PTR() before resume runs, leaving cur_sk < end_sk over slots that now hold cookies rather than sock pointers. bpf_iter_tcp_seq_stop() then calls bpf_iter_tcp_put_batch() again and dereferences a cookie as a struct sock. Empty the batch on the failure path so stop() does not release it again. The sockets were already freed by the first bpf_iter_tcp_put_batch(), so nothing leaks, and a later read() rescans the bucket from the start instead of skipping it. The sibling GFP_NOWAIT failure path still holds real socket references and is left for stop() to release. BUG: KASAN: null-ptr-deref in __sock_gen_cookie Read of size 8 at addr 0000000000000059 by task exploit ... __sock_gen_cookie (net/core/sock_diag.c:28) bpf_iter_tcp_put_batch (net/ipv4/tcp_ipv4.c:2918) bpf_iter_tcp_seq_stop (net/ipv4/tcp_ipv4.c:3270) bpf_seq_read (kernel/bpf/bpf_iter.c:205) vfs_read (fs/read_write.c:572) ksys_read (fs/read_write.c:716) do_syscall_64 entry_SYSCALL_64_after_hwframe Kernel panic - not syncing: Fatal exception
Title bpf: tcp: fix double sock release on batch realloc
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-19T20:48:42.635Z

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

Link: CVE-2026-64575

cve-icon Vulnrichment

Updated: 2026-10-16T15:43:09.675Z

cve-icon NVD

Status : Received

Published: 2026-08-05T08:16:37.363

Modified: 2026-10-19T21:17:47.840

Link: CVE-2026-64575

cve-icon Redhat

Severity : Moderate

Publid Date: 2026-08-05T00:00:00Z

Links: CVE-2026-64575 - Bugzilla

cve-icon OpenCVE Enrichment

Updated: 2026-10-20T13:45:13Z

Weaknesses