syscall_intercept
syscall_intercept copied to clipboard
Workaround SYS_clone3 in Ubuntu 22.04
The GLIBC 2.35 in Ubuntu 22.04 uses SYS_clone3 to create threads, that seems to cause segfault in hook. I use the following workaround to force a fall back to SYS_clone.
if (syscall_number == SYS_clone3)
{
*result = -ENOSYS;
return 0;
}
But I guess this may not work if actual call is clone3.
Changing line 693 in intercept.c to:
if ( (desc.nr == SYS_clone || desc.nr == SYS_clone3) && desc.args[1] != 0)
Enables clone3 usage, no need to disable the syscall