mirror of
https://github.com/google/sandboxed-api.git
synced 2024-03-22 13:11:30 +08:00
On new process, check for the clone3 syscall.
PiperOrigin-RevId: 499918752 Change-Id: I7279e76593976c224a15be901834bf6225aebe85
This commit is contained in:
parent
90ee0a7464
commit
756176f206
|
@ -1001,6 +1001,9 @@ void Monitor::EventPtraceNewProcess(pid_t pid, int event_msg) {
|
||||||
if (index != syscalls_in_progress_.end()) {
|
if (index != syscalls_in_progress_.end()) {
|
||||||
auto syscall_nr = index->second.nr();
|
auto syscall_nr = index->second.nr();
|
||||||
bool creating_new_process = syscall_nr == __NR_clone;
|
bool creating_new_process = syscall_nr == __NR_clone;
|
||||||
|
#ifdef __NR_clone3
|
||||||
|
creating_new_process = creating_new_process || syscall_nr == __NR_clone3;
|
||||||
|
#endif
|
||||||
#ifdef __NR_fork
|
#ifdef __NR_fork
|
||||||
creating_new_process = creating_new_process || syscall_nr == __NR_fork;
|
creating_new_process = creating_new_process || syscall_nr == __NR_fork;
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue
Block a user