diff options
author | Casey Schaufler <casey@schaufler-ca.com> | 2013-10-22 11:47:45 -0700 |
---|---|---|
committer | Casey Schaufler <casey@schaufler-ca.com> | 2013-10-28 10:23:36 -0700 |
commit | b5dfd8075bc26636d11c3d8888940198afbf5112 (patch) | |
tree | 65c10996178b210a5d7223489cf8d5332bc9c273 /security/smack | |
parent | c0ab6e56dcb7ca9903d460247cb464e769ae6e77 (diff) | |
download | linux-b5dfd8075bc26636d11c3d8888940198afbf5112.tar.bz2 |
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
Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
Diffstat (limited to 'security/smack')
-rw-r--r-- | security/smack/smack_lsm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c index 88d366e55793..b0be893ad44d 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; } |