kernel_optimize_test/security
Casey Schaufler 2784604c8c LSM: general protection fault in legacy_parse_param
[ Upstream commit ecff30575b5ad0eda149aadad247b7f75411fd47 ]

The usual LSM hook "bail on fail" scheme doesn't work for cases where
a security module may return an error code indicating that it does not
recognize an input.  In this particular case Smack sees a mount option
that it recognizes, and returns 0. A call to a BPF hook follows, which
returns -ENOPARAM, which confuses the caller because Smack has processed
its data.

The SELinux hook incorrectly returns 1 on success. There was a time
when this was correct, however the current expectation is that it
return 0 on success. This is repaired.

Reported-by: syzbot+d1e3b1d92d25abf97943@syzkaller.appspotmail.com
Signed-off-by: Casey Schaufler <casey@schaufler-ca.com>
Acked-by: James Morris <jamorris@linux.microsoft.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2022-04-08 14:40:30 +02:00
..
apparmor apparmor: fix error check 2021-11-18 14:04:22 +01:00
bpf
integrity EVM: fix the evm= __setup handler return value 2022-04-08 14:40:00 +02:00
keys KEYS: fix length validation in keyctl_pkey_params_get_2() 2022-04-08 14:39:50 +02:00
loadpin
lockdown
safesetid
selinux LSM: general protection fault in legacy_parse_param 2022-04-08 14:40:30 +02:00
smack smackfs: use netlbl_cfg_cipsov4_del() for deleting cipso_v4_doi 2021-11-18 14:04:10 +01:00
tomoyo TOMOYO: fix __setup handlers return values 2022-04-08 14:40:18 +02:00
yama
commoncap.c security: commoncap: fix -Wstringop-overread warning 2021-05-11 14:47:36 +02:00
device_cgroup.c
inode.c
Kconfig fortify: Explicitly disable Clang support 2021-11-21 13:46:35 +01:00
Kconfig.hardening
lsm_audit.c
Makefile
min_addr.c
security.c LSM: general protection fault in legacy_parse_param 2022-04-08 14:40:30 +02:00