[Kernel-packages] [Bug 1860822] Re: ptrace fails with yama/ptrace_scope=0

2020-01-26 Thread jklowden
Seth, thank you kindly for your prompt and clear answer. I modified server.c and confirm that gdb can now attach to the child process. Although prctl(PR_SET_DUMPABLE, 1) has no effect (and returns 0!) when called before resetting privileges, it works after the gid has been reset to the debugging p

[Kernel-packages] [Bug 1860822] Re: ptrace fails with yama/ptrace_scope=0

2020-01-24 Thread Seth Arnold
Hello, this appears to be working as designed. In Linux, process tracing is tied with the process dumping flag. The dumpable flag is cleared at execve(2) time when a setuid or setgid application is executed. This flag persists to child processes created by fork(2) and will only be reset when a pro