Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 86f2bc02 authored by Dmitry Kasatkin's avatar Dmitry Kasatkin Committed by Mimi Zohar
Browse files

ima: remove unnecessary appraisal test



ima_get_action() sets the "action" flags based on policy.
Before collecting, measuring, appraising, or auditing the
file, the "action" flag is updated based on the cached
iint->flags.

This patch removes the subsequent unnecessary appraisal
test in ima_appraise_measurement().

Signed-off-by: default avatarDmitry Kasatkin <d.kasatkin@samsung.com>
Signed-off-by: default avatarMimi Zohar <zohar@linux.vnet.ibm.com>
parent e4a9c519
Loading
Loading
Loading
Loading
+0 −2
Original line number Original line Diff line number Diff line
@@ -192,8 +192,6 @@ int ima_appraise_measurement(int func, struct integrity_iint_cache *iint,
	enum integrity_status status = INTEGRITY_UNKNOWN;
	enum integrity_status status = INTEGRITY_UNKNOWN;
	int rc = xattr_len, hash_start = 0;
	int rc = xattr_len, hash_start = 0;


	if (!ima_appraise)
		return 0;
	if (!inode->i_op->getxattr)
	if (!inode->i_op->getxattr)
		return INTEGRITY_UNKNOWN;
		return INTEGRITY_UNKNOWN;