summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
authorCasey Schaufler <casey@schaufler-ca.com>2013-10-22 11:47:45 -0700
committerChanho Park <chanho61.park@samsung.com>2014-11-18 11:46:06 +0900
commitc1583766db4a15236ac10ffa7cd402f7cff93f5a (patch)
tree8ec9c7350ea45e96475c2deefe6ab7dbb0da5705 /security
parentbbc26c08443a73b1f0ddf5ab38301c74a5b5157f (diff)
downloadlinux-3.10-c1583766db4a15236ac10ffa7cd402f7cff93f5a.tar.gz
linux-3.10-c1583766db4a15236ac10ffa7cd402f7cff93f5a.tar.bz2
linux-3.10-c1583766db4a15236ac10ffa7cd402f7cff93f5a.zip
Smack: Ptrace access check mode
When the ptrace security hooks were split the addition of a mode parameter was not taken advantage of in the Smack ptrace access check. This changes the access check from always looking for read and write access to using the passed mode. This will make use of /proc much happier. Targeted for git://git.gitorious.org/smack-next/kernel.git Change-Id: I979f36da1b26d0fba5d73744f340422aaae5cc74 Signed-off-by: Casey Schaufler <casey@schaufler-ca.com> Signed-off-by: Ɓukasz Stelmach <l.stelmach@samsung.com>
Diffstat (limited to 'security')
-rw-r--r--security/smack/smack_lsm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c
index 88d366e5579..b0be893ad44 100644
--- a/security/smack/smack_lsm.c
+++ b/security/smack/smack_lsm.c
@@ -185,7 +185,7 @@ static int smack_ptrace_access_check(struct task_struct *ctp, unsigned int mode)
smk_ad_init(&ad, __func__, LSM_AUDIT_DATA_TASK);
smk_ad_setfield_u_tsk(&ad, ctp);
- rc = smk_curacc(skp->smk_known, MAY_READWRITE, &ad);
+ rc = smk_curacc(skp->smk_known, mode, &ad);
return rc;
}