Page MenuHomeFreeBSD

D57346.id178948.diff
No OneTemporary

D57346.id178948.diff

Index: sys/kern/p1003_1b.c
===================================================================
--- sys/kern/p1003_1b.c
+++ sys/kern/p1003_1b.c
@@ -123,6 +123,8 @@
targettd = td;
PROC_LOCK(targetp);
} else {
+ if (IN_CAPABILITY_MODE(td) && uap->pid != td->td_proc->p_pid)
+ return (ECAPMODE);
targetp = pfind(uap->pid);
if (targetp == NULL)
return (ESRCH);
@@ -164,6 +166,8 @@
targettd = td;
PROC_LOCK(targetp);
} else {
+ if (IN_CAPABILITY_MODE(td) && uap->pid != td->td_proc->p_pid)
+ return (ECAPMODE);
targetp = pfind(uap->pid);
if (targetp == NULL) {
return (ESRCH);
@@ -211,6 +215,8 @@
targettd = td;
PROC_LOCK(targetp);
} else {
+ if (IN_CAPABILITY_MODE(td) && uap->pid != td->td_proc->p_pid)
+ return (ECAPMODE);
targetp = pfind(uap->pid);
if (targetp == NULL)
return (ESRCH);
@@ -257,6 +263,8 @@
targettd = td;
PROC_LOCK(targetp);
} else {
+ if (IN_CAPABILITY_MODE(td) && uap->pid != td->td_proc->p_pid)
+ return (ECAPMODE);
targetp = pfind(uap->pid);
if (targetp == NULL)
return (ESRCH);

File Metadata

Mime Type
text/plain
Expires
Wed, Jul 22, 6:39 PM (14 h, 31 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
35376846
Default Alt Text
D57346.id178948.diff (1 KB)

Event Timeline