diff options
author | Casey Schaufler <casey@schaufler-ca.com> | 2013-12-30 20:37:45 -0500 |
---|---|---|
committer | Casey Schaufler <casey@schaufler-ca.com> | 2013-12-31 16:35:27 -0500 |
commit | 4482a44f6a3221cd0076eb6af65672a7e198d8da (patch) | |
tree | 5caa99f7179486a64399de14496fba56a88cb7e9 /security | |
parent | 24ea1b6efcd8fc3b465fb74964e1a0cbe9979730 (diff) |
Smack: File receive audit correction
Eric Paris politely points out:
Inside smack_file_receive() it seems like you are initting the audit
field with LSM_AUDIT_DATA_TASK. And then use
smk_ad_setfield_u_fs_path().
Seems like LSM_AUDIT_DATA_PATH would make more sense. (and depending
on how it's used fix a crash...)
He is correct. This puts things in order.
Targeted for git://git.gitorious.org/smack-next/kernel.git
Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
Diffstat (limited to 'security')
-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 d5528324a637..d814e35987be 100644 --- a/security/smack/smack_lsm.c +++ b/security/smack/smack_lsm.c | |||
@@ -1351,7 +1351,7 @@ static int smack_file_receive(struct file *file) | |||
1351 | int may = 0; | 1351 | int may = 0; |
1352 | struct smk_audit_info ad; | 1352 | struct smk_audit_info ad; |
1353 | 1353 | ||
1354 | smk_ad_init(&ad, __func__, LSM_AUDIT_DATA_TASK); | 1354 | smk_ad_init(&ad, __func__, LSM_AUDIT_DATA_PATH); |
1355 | smk_ad_setfield_u_fs_path(&ad, file->f_path); | 1355 | smk_ad_setfield_u_fs_path(&ad, file->f_path); |
1356 | /* | 1356 | /* |
1357 | * This code relies on bitmasks. | 1357 | * This code relies on bitmasks. |