Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 361879
b: refs/heads/master
c: eddc0a3
h: refs/heads/master
i:
  361877: 7555012
  361875: da3f06c
  361871: 6f0fd9c
v: v3
  • Loading branch information
Eric W. Biederman committed Mar 26, 2013
1 parent e95c15e commit 346a167
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 751c644b95bb48aaa8825f0c66abbcc184d92051
refs/heads/master: eddc0a3abff273842a94784d2d022bbc36dc9015
4 changes: 1 addition & 3 deletions trunk/security/yama/yama_lsm.c
Original file line number Diff line number Diff line change
Expand Up @@ -347,10 +347,8 @@ int yama_ptrace_traceme(struct task_struct *parent)
/* Only disallow PTRACE_TRACEME on more aggressive settings. */
switch (ptrace_scope) {
case YAMA_SCOPE_CAPABILITY:
rcu_read_lock();
if (!ns_capable(__task_cred(parent)->user_ns, CAP_SYS_PTRACE))
if (!has_ns_capability(parent, current_user_ns(), CAP_SYS_PTRACE))
rc = -EPERM;
rcu_read_unlock();
break;
case YAMA_SCOPE_NO_ATTACH:
rc = -EPERM;
Expand Down

0 comments on commit 346a167

Please sign in to comment.