-
Notifications
You must be signed in to change notification settings - Fork 667
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ptrace: add PTRACE_O_EXITKILL option #771
Conversation
@bpowers no, there's no way to conditionally build stuff based on kernel version. It's up to the application to check for |
src/sys/ptrace.rs
Outdated
@@ -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")] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be available on Android as well. Please keep the OSes listed in alphabetical order here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch! updated diff.
It is a somewhat newer option -- it requires Linux 3.8.
that errored Travis test is unrelated to this -- seems to be some NetBSD problem? |
bors r+ |
awesome, thanks!! |
Thank you for your contribution to nix! |
It is a somewhat newer option -- it requires Linux 3.8. Is there a
more precise way to specify that?