summaryrefslogtreecommitdiff
path: root/kernel_headers.py
diff options
context:
space:
mode:
authorJann Horn <jannh@google.com>2019-03-30 03:12:32 +0100
committerBruno Martins <bgcngm@gmail.com>2022-10-28 15:57:23 +0100
commit229e1bdd624eb6e2a4b946ae938485a05b37438a (patch)
tree839761cf5ba16218ed7a9395ed387fc592e8189a /kernel_headers.py
parentada02e996b52d9389d76b72213e01ffcdd648e96 (diff)
UPSTREAM: signal: don't silently convert SI_USER signals to non-current pidfd
The current sys_pidfd_send_signal() silently turns signals with explicit SI_USER context that are sent to non-current tasks into signals with kernel-generated siginfo. This is unlike do_rt_sigqueueinfo(), which returns -EPERM in this case. If a user actually wants to send a signal with kernel-provided siginfo, they can do that with pidfd_send_signal(pidfd, sig, NULL, 0); so allowing this case is unnecessary. Instead of silently replacing the siginfo, just bail out with an error; this is consistent with other interfaces and avoids special-casing behavior based on security checks. Fixes: 3eb39f47934f ("signal: add pidfd_send_signal() syscall") Signed-off-by: Jann Horn <jannh@google.com> Signed-off-by: Christian Brauner <christian@brauner.io> (cherry picked from commit 556a888a14afe27164191955618990fb3ccc9aad) Bug: 135608568 Test: test program using syscall(__NR_pidfd_send_signal,..) to send SIGKILL Change-Id: I493af671b82c43bff1425ee24550d2fb9aa6d961 Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Diffstat (limited to 'kernel_headers.py')
0 files changed, 0 insertions, 0 deletions