ubpf
ubpf copied to clipboard
Incorrect exit implementation in JIT compiler
When we run PoC program in the JIT compiler, we get the return value as 224
after execution. While the correct return value should be 0
.
The code generation implementation of EBPF_OP_EXIT
in JIT compiler does not correctly handle the initial r0
value.
mov %r2, 0xFFFFFFFF
exit
We observed the following inconsistency:
// result after program execution
interpreter: 0
JIT: 224