p_cansignal() returns an errno value; at some point, the check for
inter-process signalling ceased to preserve and return that value, instead always returning EPERM. This meant that it was possible to "probe" the pid space for processes that were not otherwise visible. This change reverts that reversion. Obtained from: TrustedBSD Project Sponsored by: DARPA, NAI Labs
This commit is contained in:
parent
5706d2e811
commit
661016419c
@ -1084,9 +1084,9 @@ kill(td, uap)
|
||||
/* kill single process */
|
||||
if ((p = pfind(uap->pid)) == NULL) {
|
||||
error = ESRCH;
|
||||
} else if (p_cansignal(td->td_proc, p, uap->signum)) {
|
||||
} else if ((error = p_cansignal(td->td_proc, p, uap->signum))
|
||||
!= 0) {
|
||||
PROC_UNLOCK(p);
|
||||
error = EPERM;
|
||||
} else {
|
||||
if (uap->signum)
|
||||
psignal(p, uap->signum);
|
||||
|
Loading…
Reference in New Issue
Block a user