In terminate_monitor_hook.cpp, add_redirect rewrites ZwTerminateProcess with 0x20 bytes, but there is a important API ZwTerminateThread beside ZwTerminateProcess, and add_redirect will mess up ZwTerminateThread.
This commit fixes this problem by rewriting ZwTerminateProcess only with a near jmp, which costs only 5 bytes.
In terminate_monitor_hook.cpp,
add_redirect
rewritesZwTerminateProcess
with 0x20 bytes, but there is a important APIZwTerminateThread
besideZwTerminateProcess
, andadd_redirect
will mess upZwTerminateThread
.This commit fixes this problem by rewriting
ZwTerminateProcess
only with a near jmp, which costs only 5 bytes.