linux/fs
Roberto Sassu 9238311176 evm: Move to LSM infrastructure
As for IMA, move hardcoded EVM function calls from various places in the
kernel to the LSM infrastructure, by introducing a new LSM named 'evm'
(last and always enabled like 'ima'). The order in the Makefile ensures
that 'evm' hooks are executed after 'ima' ones.

Make EVM functions as static (except for evm_inode_init_security(), which
is exported), and register them as hook implementations in init_evm_lsm().
Also move the inline functions evm_inode_remove_acl(),
evm_inode_post_remove_acl(), and evm_inode_post_set_acl() from the public
evm.h header to evm_main.c.

Unlike before (see commit to move IMA to the LSM infrastructure),
evm_inode_post_setattr(), evm_inode_post_set_acl(),
evm_inode_post_remove_acl(), and evm_inode_post_removexattr() are not
executed for private inodes.

Finally, add the LSM_ID_EVM case in lsm_list_modules_test.c

Signed-off-by: Roberto Sassu <roberto.sassu@huawei.com>
Reviewed-by: Casey Schaufler <casey@schaufler-ca.com>
Acked-by: Christian Brauner <brauner@kernel.org>
Reviewed-by: Stefan Berger <stefanb@linux.ibm.com>
Reviewed-by: Mimi Zohar <zohar@linux.ibm.com>
Acked-by: Mimi Zohar <zohar@linux.ibm.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
2024-02-15 23:43:47 -05:00
..
9p
adfs
affs
afs afs: Fix missing/incorrect unlocking of RCU read lock 2024-01-22 22:30:38 +00:00
autofs
bcachefs bcachefs: __lookup_dirent() works in snapshot, not subvol 2024-01-25 20:02:11 -05:00
befs
bfs
btrfs Revert "btrfs: zstd: fix and simplify the inline extent decompression" 2024-01-22 15:39:01 -08:00
cachefiles cachefiles, erofs: Fix NULL deref in when cachefiles is not doing ondemand-mode 2024-01-22 22:25:15 +00:00
ceph Assorted CephFS fixes and cleanups with nothing standing out. 2024-01-19 09:58:55 -08:00
coda
configfs
cramfs
crypto
debugfs
devpts
dlm
ecryptfs
efivarfs
efs
erofs erofs: relaxed temporary buffers allocation on readahead 2024-01-27 12:28:08 +08:00
exfat
exportfs
ext2
ext4 Miscellaneous bug fixes and cleanups in ext4's multi-block allocator 2024-02-04 07:33:01 +00:00
f2fs
fat
freevxfs
fuse
gfs2 Revert "gfs2: Use GL_NOBLOCK flag for non-blocking lookups" 2024-02-02 17:21:44 +01:00
hfs
hfsplus
hostfs
hpfs
hugetlbfs fs/hugetlbfs/inode.c: mm/memory-failure.c: fix hugetlbfs hwpoison handling 2024-01-25 23:52:20 -08:00
iomap
isofs
jbd2
jffs2
jfs Revert "jfs: fix shift-out-of-bounds in dbJoin" 2024-01-29 08:45:10 -06:00
kernfs
lockd
minix
netfs netfs: Fix a NULL vs IS_ERR() check in netfs_perform_write() 2024-01-22 21:58:35 +00:00
nfs vfs-6.8.netfs 2024-01-19 09:10:23 -08:00
nfs_common
nfsd ima: Move to LSM infrastructure 2024-02-15 23:43:46 -05:00
nilfs2
nls
notify
ntfs
ntfs3
ocfs2
omfs
openpromfs
orangefs
overlayfs ovl: mark xwhiteouts directory with overlay.opaque='x' 2024-01-23 12:39:48 +02:00
proc
pstore
qnx4
qnx6
quota
ramfs
reiserfs
romfs
smb smb: client: increase number of PDUs allowed in a compound request 2024-02-01 12:15:51 -06:00
squashfs
sysfs
sysv
tracefs eventfs: Keep all directory links at 1 2024-02-01 11:53:53 -05:00
ubifs
udf
ufs
unicode
vboxsf
verity
xfs xfs: remove conditional building of rt geometry validator functions 2024-01-30 14:04:43 +05:30
zonefs
aio.c
anon_inodes.c
attr.c evm: Move to LSM infrastructure 2024-02-15 23:43:47 -05:00
backing-file.c
bad_inode.c
binfmt_elf_fdpic.c
binfmt_elf_test.c
binfmt_elf.c
binfmt_flat.c
binfmt_misc.c
binfmt_script.c
buffer.c
char_dev.c
compat_binfmt_elf.c
coredump.c
d_path.c
dax.c
dcache.c
direct-io.c
drop_caches.c
eventfd.c
eventpoll.c
exec.c execve fixes for v6.8-rc2 2024-01-24 13:32:29 -08:00
fcntl.c
fhandle.c
file_table.c ima: Move to LSM infrastructure 2024-02-15 23:43:46 -05:00
file.c
filesystems.c
fs_context.c
fs_parser.c
fs_pin.c
fs_struct.c
fs_types.c
fs-writeback.c
fsopen.c
init.c
inode.c
internal.h
ioctl.c
Kconfig vfs-6.8.netfs 2024-01-19 09:10:23 -08:00
Kconfig.binfmt
kernel_read_file.c
libfs.c
locks.c
Makefile vfs-6.8.netfs 2024-01-19 09:10:23 -08:00
mbcache.c
mnt_idmapping.c
mount.h
mpage.c
namei.c ima: Move to LSM infrastructure 2024-02-15 23:43:46 -05:00
namespace.c
nsfs.c
open.c ima: Move to LSM infrastructure 2024-02-15 23:43:46 -05:00
pipe.c
pnode.c
pnode.h
posix_acl.c evm: Move to LSM infrastructure 2024-02-15 23:43:47 -05:00
proc_namespace.c
read_write.c
readdir.c
remap_range.c
select.c
seq_file.c
signalfd.c
splice.c
stack.c
stat.c
statfs.c
super.c
sync.c
sysctls.c
timerfd.c
userfaultfd.c
utimes.c
xattr.c evm: Move to LSM infrastructure 2024-02-15 23:43:47 -05:00