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-98628 Overview
CVE-2026-98628 is a Linux kernel vulnerability in the Berkeley Packet Filter (BPF) verifier. After do_check() completes, the verifier performs post-verification instruction rewrite passes that neither check for pending signals nor reschedule. A privileged loader can submit 131,072 unconditional zero-jump instructions followed by a valid return, triggering quadratic-time work in bpf_opt_remove_nops(). The task cannot be terminated by SIGKILL until the rewrite completes.
The fix converts bpf_patch_insn_data() and verifier_remove_insns() into cancellation and rescheduling points, allowing killed loaders to be torn down promptly.
Critical Impact
A privileged BPF loader can monopolize kernel CPU time with non-preemptible verifier work, blocking SIGKILL delivery and causing denial-of-service conditions on affected systems.
Affected Products
- Linux kernel versions containing the pre-patch BPF verifier instruction rewrite logic
- Stable kernel branches referenced in commits 261b61d3735b and 56dc616d7a1f
- Systems permitting privileged BPF program loading via BPF_PROG_LOAD
Discovery Timeline
- 2026-10-18 - CVE-2026-98628 published to NVD
- 2026-10-19 - Last updated in NVD database
Technical Details for CVE-2026-98628
Vulnerability Analysis
The Linux kernel BPF verifier executes multiple instruction rewrite passes after do_check() returns. These passes patch or remove one instruction at a time, moving the remaining instruction and auxiliary-data arrays and adjusting all branch offsets on every operation. The cumulative work scales quadratically with program length.
A privileged loader can craft a BPF program containing 131,072 unconditional zero-displacement jumps followed by a valid return. Verification itself completes quickly. However, bpf_opt_remove_nops() then spends extended CPU time removing each jump individually. Because the post-verification code neither tests for pending signals nor voluntarily reschedules, the task becomes effectively uninterruptible. A pending SIGKILL cannot terminate the loader until the rewrite finishes.
This classifies as an algorithmic complexity denial-of-service issue in a non-preemptible kernel code path. The patch does not reduce the quadratic cost but converts the rewrite loops into preemption and cancellation points.
Root Cause
The root cause is missing cond_resched() and signal-check logic inside bpf_patch_insn_data() and verifier_remove_insns(). These helpers run in BPF_PROG_LOAD process context and bpf_patch_insn_data() can already sleep during auxiliary-data reallocation, making them safe locations to add cancellation points.
Attack Vector
Exploitation requires CAP_BPF or equivalent privilege to invoke BPF_PROG_LOAD. A local privileged actor submits a maximally sized program whose structure maximizes the number of nop-removal operations. The verifier accepts the program, but kernel CPU time is consumed in a non-preemptible rewrite loop. Even administrator-issued kill -9 cannot promptly reclaim the task.
No verified proof-of-concept code is published with this advisory. See the referenced Kernel Git Commit Log for the patch implementation details.
Detection Methods for CVE-2026-98628
Indicators of Compromise
- Processes invoking bpf() syscall with BPF_PROG_LOAD command that remain in running state for extended periods and ignore SIGKILL.
- Elevated kernel-mode CPU utilization on cores servicing BPF verification requests.
- Audit log entries recording large BPF program submissions from privileged user contexts.
Detection Strategies
- Monitor bpf() syscall telemetry via auditd or eBPF tracing for programs exceeding abnormal instruction counts.
- Alert on tasks accumulating sustained kernel CPU time while flagged for termination.
- Correlate BPF_PROG_LOAD events with sudden drops in system responsiveness or scheduler latency spikes.
Monitoring Recommendations
- Enable Linux audit rules targeting the bpf syscall and track cmd=BPF_PROG_LOAD events with program size metadata.
- Track per-process scheduler statistics in /proc/<pid>/status and /proc/<pid>/sched for uninterruptible kernel execution.
- Baseline normal BPF loader behavior for container runtimes, observability agents, and networking stacks to surface anomalous submissions.
How to Mitigate CVE-2026-98628
Immediate Actions Required
- Apply the upstream Linux kernel patches referenced in commits 261b61d3735b042ae25634f795c4540be0fc140c and 56dc616d7a1f7d134d3e101c455e62b0a24d0cfd.
- Restrict CAP_BPF and CAP_SYS_ADMIN to trusted workloads only, and audit which service accounts can load BPF programs.
- Review container and orchestration policies that grant BPF privileges to pods or sidecars.
Patch Information
The fix converts bpf_patch_insn_data() and verifier_remove_insns() into common cancellation and rescheduling points. Interrupted constant blinding is reported as -EINTR and propagated through both just-in-time (JIT) compilation paths, including kernels permitting interpreter fallback. Other blinding failures retain existing fallback behavior. Patches are available via the stable kernel tree.
Workarounds
- Disable unprivileged BPF program loading by setting kernel.unprivileged_bpf_disabled=1 via sysctl where supported.
- Use Linux Security Modules (SELinux, AppArmor) to constrain which processes may invoke BPF_PROG_LOAD.
- Apply seccomp filters in container runtimes to block the bpf() syscall for workloads that do not require it.
# Configuration example: restrict unprivileged BPF and audit bpf() syscalls
sysctl -w kernel.unprivileged_bpf_disabled=1
echo 'kernel.unprivileged_bpf_disabled=1' >> /etc/sysctl.d/99-bpf-hardening.conf
# Add audit rule for BPF program loads
auditctl -a always,exit -F arch=b64 -S bpf -k bpf_syscall
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

