lkml.org 
[lkml]   [2015]   [May]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RESEND PATCH] Smack: ignore private inode for smack_file_receive
Ping?

On 2015년 04월 17일 15:25, Seung-Woo Kim wrote:
> The dmabuf fd can be shared between processes via unix domain
> socket. The file of dmabuf fd is came from anon_inode. The inode
> has no set and get xattr operations, so it can not be shared
> between processes with smack. This patch fixes just to ignore
> private inode including anon_inode for smack_file_receive.
>
> Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
> ---
> I think there was some issue sending my previous mail, so I resend patch again.
> ---
> security/smack/smack_lsm.c | 3 +++
> 1 files changed, 3 insertions(+), 0 deletions(-)
>
> diff --git a/security/smack/smack_lsm.c b/security/smack/smack_lsm.c
> index 69fdc38..d1bb411 100644
> --- a/security/smack/smack_lsm.c
> +++ b/security/smack/smack_lsm.c
> @@ -1673,6 +1673,9 @@ static int smack_file_receive(struct file *file)
> struct smk_audit_info ad;
> struct inode *inode = file_inode(file);
>
> + if (unlikely(IS_PRIVATE(inode)))
> + return 0;
> +
> smk_ad_init(&ad, __func__, LSM_AUDIT_DATA_PATH);
> smk_ad_setfield_u_fs_path(&ad, file->f_path);
> /*
>

--
Seung-Woo Kim
Samsung Software R&D Center
--



\
 
 \ /
  Last update: 2015-05-11 10:41    [W:0.046 / U:10.204 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site