KernelScan.io

HIGH

bpf TrampolineFlags Race

CVE-2026-92485

CVSS 7.8 / 10.0 NVD

CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H

KernelScan AI4.7MEDIUM

01

In the Linux kernel, the following vulnerability has been resolved: bpf: Fix WARNING in bpf_tracing_link_release The trampoline could be corrupted by the blindly 'tr->flags = BPF_TRAMP_F_TAIL_CALL_CTX' in verifier. 1. A fexit attached to a tail_call_reachable prog. 'tr->flags' became 'BPF_TRAMP_F_CALL_ORIG | BPF_TRAMP_F_TAIL_CALL_CTX'. And, the trampoline would poke the target prog's nop insn using jmp insn instead of call insn. 2. Another fexit loaded with the same tail_call_reachable prog target. 'tr->flags' became 'BPF_TRAMP_F_TAIL_CALL_CTX'. 3. Close the first fexit link. Due to no BPF_TRAMP_F_CALL_ORIG in 'tr->flags', the trampoline will fail to restore the prog's nop insn using call insn. [ 3.410719] WARNING: kernel/bpf/syscall.c:3551 at bpf_tracing_link_release+0x53/0x60, CPU#1: test_progs/98 ... [ 3.428793] bpf_link_free+0x58/0x130 [ 3.429293] bpf_link_release+0x23/0x30 Fix the warning by updating 'tr->flags' with '|=' and lock.

02

Engine v0.6.0

Risk summary

A race condition in the BPF verifier's trampoline flag handling allows a local attacker with BPF privileges to corrupt trampoline state, leading to a kernel warning and potential denial of service. The bug requires loading multiple BPF programs targeting the same tail-call-reachable program in a specific sequence.

Affectedkernel/bpf/verifier.c (bpf subsystem)

Vulnerability analysis

The BPF verifier unconditionally overwrites a shared trampoline's flags field when attaching to a tail-call-reachable program, without holding the trampoline lock. If two attachments target the same program, the second one can clobber flags set by the first, causing the trampoline to lose a flag needed to correctly restore the target program's instructions during teardown. The fix changes the assignment to an atomic bitwise-OR under the trampoline lock, so flags accumulate rather than replace each other. This is reachable from a local process with BPF program loading privileges (CAP_BPF or equivalent).

03

BranchIntroducedFixed inPatch commit
6.66.6.26.7—
7.2—7.2.6—
mainline—7.3-rc1—
6.16.1.726.248a0209d8da0
6.56.5.126.661aaa8782bec