Smack: ignore private inode for file functions
authorSeung-Woo Kim <sw0312.kim@samsung.com>
Mon, 12 Dec 2016 08:35:26 +0000 (17:35 +0900)
committerJaechul Lee <jcsing.lee@samsung.com>
Tue, 14 Feb 2017 04:26:27 +0000 (13:26 +0900)
commit306b09ff3be45cbcb8b506e06db03aaaa092483f
tree7fb5086be6e7cb453459b99220d7e8b52cc8d1af
parent6dfda119f2373601c9b9f686b503490e05f057cc
Smack: ignore private inode for file functions

The access to fd from anon_inode is always failed because there is
no set xattr operations. So this patch fixes to ignore private
inode including anon_inode for file functions.

It was only ignored for smack_file_receive() to share dma-buf fd,
but dma-buf has other functions like ioctl and mmap.

Reference: https://lkml.org/lkml/2015/4/17/16

Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
security/smack/smack_lsm.c