projects
/
linux-flexiantxendom0-natty.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7d9570a
)
UBUNTU: SAUCE: Yama: check PTRACE using thread group leader
author
Kees Cook <kees.cook@canonical.com>
Sat, 10 Jul 2010 19:12:20 +0000
(12:12 -0700)
committer
Leann Ogasawara <leann.ogasawara@canonical.com>
Mon, 28 Mar 2011 13:48:57 +0000
(06:48 -0700)
When examining process ancestory, we must use the thread group leader
or else we end up missing potential matches.
[submitted upstream to security-next]
Signed-off-by: Kees Cook <kees.cook@canonical.com>
Signed-off-by: Leann Ogasawara <leann.ogasawara@canonical.com>
security/yama/yama_lsm.c
patch
|
blob
|
history
diff --git
a/security/yama/yama_lsm.c
b/security/yama/yama_lsm.c
index
291a9e5
..
b28d9cc
100644
(file)
--- a/
security/yama/yama_lsm.c
+++ b/
security/yama/yama_lsm.c
@@
-170,6
+170,8
@@
static int task_is_descendant(struct task_struct *parent,
rcu_read_lock();
read_lock(&tasklist_lock);
while (walker->pid > 0) {
+ if (!thread_group_leader(walker))
+ walker = walker->group_leader;
if (walker == parent) {
rc = 1;
break;