Skip to content

Commit

Permalink
ptrace: add PTRACE_O_EXITKILL option
Browse files Browse the repository at this point in the history
It is a somewhat newer option -- it requires Linux 3.8. Is there a
more precise way to specify that?
  • Loading branch information
bpowers committed Sep 24, 2017
1 parent 9f4db8a commit 5558214
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/sys/ptrace.rs
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,10 @@ libc_bitflags! {
/// Stop tracee when a SECCOMP_RET_TRACE rule is triggered. See `man seccomp` for more
/// details.
PTRACE_O_TRACESECCOMP;
/// Send a SIGKILL to the tracee if the tracer exits. This is useful
/// for ptrace jailers to prevent tracees from escaping their control.
#[cfg(target_os = "linux")]
PTRACE_O_EXITKILL;
}
}

Expand Down

0 comments on commit 5558214

Please sign in to comment.