CVE-2026-143381: x86/ftrace: Mark jmp mode by clearing bit 63 of trampoline address

Published Dec 3, 2026
·
Updated

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 DYNAMICFTRACEWITHJMP") ftracecallreplace() 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. ftraceupdateftracefunc() and archftraceupdatetrampoline() use it too, for the call of the ftrace callback in ftracecaller, ftraceregscaller and the ftrace trampolines, but a callback is a C function and can start at an odd address. It does with gcc13 and CONFIGCCOPTIMIZEFORSIZE=y: gcc13 has no -fmin-function-alignment, so CONFIGCCHASSANEFUNCTIONALIGNMENT is not set, and the -falign-functions=16 used in its place does not apply to functions optimized for size. Here ftraceopslistfunc() starts at:

ffffffff810e0147 T ftraceopslistfunc

ftraceregscall then becomes a jmp to the byte before it:

ftraceregscall 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 ftraceopslistfunc() 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 ptregs that ftraceregscaller 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: ? bpftrampoline6442499918+0x1/0x149 ? bpflsmfileopen+0x5/0x8 ? bpflsmfileopen+0x5/0x8 ? securityfileopen+0x19/0x46 ? dodentryopen+0x16c/0x32a

The list function is installed whenever two ftraceops 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 ftraceops of the BPF trampolines every updateftracedirectmod() 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 dynftrace record can point to, but bit 63 is set in every kernel text address on x8664. Thus, mark jmp mode by clearing bit 63 instead, so that ftraceisjmp() is false for any callback, whatever its alignment, and ftraceregscaller 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 ftracejmpget() faults instead of running from a byte before its target.

Affected Software

4 affected componentsFixes available
Linux Linux kernel
linux/kernel>=6.19.0<7.3.7
7.3.7
debian/linux*
debian/linux<=7.3.6-1
7.3.7-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade linux/Kernel to a version that resolves this vulnerability.

    Fixed in 7.3.7
  2. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 7.3.7-1

Event History

Dec 3, 2026
CVE Published
via MITRE·09:22 AM
Data Sourced
via MITRE·09:22 AM
Description
Data Sourced
via OSV·09:22 AM
DescriptionAffected Software
Data Sourced
via NVD·10:18 AM
Description

Frequently Asked Questions

1

Which kernel build configurations are most likely to be affected?

The described case occurs with GCC 13 and CONFIG_CC_OPTIMIZE_FOR_SIZE=y. In that setup, CONFIG_CC_HAS_SANE_FUNCTION_ALIGNMENT is not set, and the replacement -falign-functions=16 does not apply to size-optimized functions.

2

What condition triggers the faulty control transfer?

A callback implemented as a C function can begin at an odd address. The ftrace logic interprets bit 0 of the target address as a request to emit a jump, which can redirect execution to the byte before that callback instead of its first instruction.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203