git: kernel - Restrict kill(-1, ...) to the reaper group as well
Matthew Dillon
dillon at crater.dragonflybsd.org
Thu Sep 28 12:58:05 PDT 2017
commit a73d77929c33c0ff28a0a1456ccd3bce72cd5726
Author: Matthew Dillon <dillon at apollo.backplane.com>
Date: Thu Sep 28 12:55:19 2017 -0700
kernel - Restrict kill(-1, ...) to the reaper group as well
* When kill(-1, ...) is issued to 'all processes', restrict the list
of processes signaled to the sender's reaper group or any sub-group
of that group.
* This works around issues found when testing low maxproc limits.
At least one (and probably several) third party programs do not
properly handle errors when [v]fork() returns -1 and may try to
signal the returned 'pid', which being -1 crowbars the entire system.
* Fixes issue when a cmake running under synth hits a fork failure
and tries to signal the whole system. With this change, the cmake
winds up only crowbaring its own chroot due to synthexec's use of
the reaper feature.
* Adjust the kill.2 manual page to reflect the change.
Summary of changes:
lib/libc/sys/kill.2 | 4 ++++
sys/kern/kern_fork.c | 41 +++++++++++++++++++++++++++++++++++++++++
sys/kern/kern_sig.c | 15 +++++++++------
sys/sys/proc.h | 1 +
4 files changed, 55 insertions(+), 6 deletions(-)
http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/a73d77929c33c0ff28a0a1456ccd3bce72cd5726
--
DragonFly BSD source repository
More information about the Commits
mailing list