Skip to content

resend, ptrace && SIGKILL fixes

Oleg Nesterov lkml 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3ptrace: give more respect to SIGKILLinclude/linux/sched.h+0 -30 replies
2/3ptrace: never sleep in TASK_TRACED if SIGKILL'edkernel/signal.c+4 -180 replies
3/3ptrace: kill may_ptrace_stop()kernel/signal.c+1 -210 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/3] resend, ptrace && SIGKILL fixes
Quoted 4 lines · Oleg Nesterov

These 2 patches don't depend on each other. Each change is user visible, and I am not really sure it can't confuse debuggers/etc. The explicit ack/nack from maintainers is wanted.

I'm mostly worried about do_exit()->ptrace_notify(), with these patches we never notify the tracer if the tracee was SIGKILL'ed. The current behaviour depends on arch_ptrace_stop_needed(), this is not good either.

Anyway, I think these patches are fixes. Suppose we send SIGKILL to the traced task which does ptrace_notify(). If the signal is delivered before ptrace_notify() takes ->siglock, the tracee sleeps in TASK_TRACED state and becomes "unkillable". If ptrace_notify() wins, we kill the tracee. This can't be good.

The 3rd patch is new.

Oleg.