PT-2026-167239

CVE-2026-143381

·

Publicado

2026-12-03

·

Atualizado

2026-12-03

Descrição por

Pontuação
N/A
Não disponível

Não há classificações de severidade ou métricas disponíveis. Quando houver, atualizaremos as informações correspondentes na página.

In the Linux kernel, the following vulnerability has been resolved:
x86/ftrace: Mark jmp mode by clearing bit 63 of trampoline address
Since commit 0c3772a8db1f ("x86/ftrace: Implement DYNAMIC FTRACE WITH JMP") ftrace call replace() emits a jmp instead of a call when bit 0 of the target is set, the mark of a direct trampoline that is entered by a jmp. ftrace update ftrace func() and arch ftrace update trampoline() use it too, for the call of the ftrace callback in ftrace caller, ftrace regs caller and the ftrace trampolines, but a callback is a C function and can start at an odd address. It does with gcc13 and CONFIG CC OPTIMIZE FOR SIZE=y: gcc13 has no -fmin-function-alignment, so CONFIG CC HAS SANE FUNCTION ALIGNMENT is not set, and the -falign-functions=16 used in its place does not apply to functions optimized for size. Here ftrace ops list func() starts at:
ffffffff810e0147 T ftrace ops list func
ftrace regs call then becomes a jmp to the byte before it:
ftrace regs call ffffffff810374f3: e9 4e 8c 0a 00
That byte is the last one of the preceding function's tail jump, and with the first two of ftrace ops list func() it decodes as an inc DWORD PTR [rcx+0x57], which swallows the push %r15 of the prologue. Entered without a return address and one push short, the list function returns through the pt regs that ftrace regs caller saved, here to the saved R14:
BUG: unable to handle page fault for address: ffff888116c29f40 #PF: supervisor instruction fetch in kernel mode RIP: 0010:0xffff888116c29f40 R13: 0000000000000000 R14: ffff888116c29f40 R15: 0000000000000000 Call Trace: ? bpf trampoline 6442499918+0x1/0x149 ? bpf lsm file open+0x5/0x8 ? bpf lsm file open+0x5/0x8 ? security file open+0x19/0x46 ? do dentry open+0x16c/0x32a
The list function is installed whenever two ftrace ops are registered, and a function that two of them trace calls it. A kprobe next to a BPF trampoline is one such case, and with the single ftrace ops of the BPF trampolines every update ftrace direct mod() is another, as it registers a stub ops for the sites it modifies. Here, detaching one of several BPF LSM programs from a busy hook crashed the tasks that ran the hook during the update.
Bit 0 is free only in the direct trampolines that a dyn ftrace record can point to, but bit 63 is set in every kernel text address on x86 64. Thus, mark jmp mode by clearing bit 63 instead, so that ftrace is jmp() is false for any callback, whatever its alignment, and ftrace regs caller sets the bit again where it cleared bit 0 before. A marked address is not canonical, so a return or indirect branch to one that missed ftrace jmp get() faults instead of running from a byte before its target.
Fornecedores
Produtos afetados
Identificadores relacionados
Encontrou algum problema na descrição? Tem algo a acrescentar? Fique à vontade para nos escrever 👾