tmp_suning_uos_patched/security/integrity/evm
Colin Ian King 72acd64df4 EVM: Fix null dereference on xattr when xattr fails to allocate
In the case where the allocation of xattr fails and xattr is NULL, the
error exit return path via label 'out' will dereference xattr when
kfree'ing xattr-name.  Fix this by only kfree'ing xattr->name and xattr
when xattr is non-null.

Detected by CoverityScan, CID#1469366 ("Dereference after null check")

Fixes: fa516b66a1 ("EVM: Allow runtime modification of the set of verified xattrs")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Mimi Zohar <zohar@linux.vnet.ibm.com>
2018-05-31 10:13:23 -04:00
..
evm_crypto.c EVM: Allow runtime modification of the set of verified xattrs 2018-05-18 15:34:45 -04:00
evm_main.c EVM: Allow runtime modification of the set of verified xattrs 2018-05-18 15:34:45 -04:00
evm_posix_acl.c ima: fix script messages 2013-10-25 13:17:19 -04:00
evm_secfs.c EVM: Fix null dereference on xattr when xattr fails to allocate 2018-05-31 10:13:23 -04:00
evm.h EVM: turn evm_config_xattrnames into a list 2018-05-18 15:34:36 -04:00
Kconfig EVM: Allow runtime modification of the set of verified xattrs 2018-05-18 15:34:45 -04:00
Makefile evm: posix acls modify i_mode 2011-09-14 15:24:51 -04:00