Message ID | 20240905152512.3781098-3-roberto.sassu@huaweicloud.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | ima: Integrate with Integrity Digest Cache | expand |
diff --git a/security/integrity/ima/ima_main.c b/security/integrity/ima/ima_main.c index cff8b5a12512..06ee99bd7886 100644 --- a/security/integrity/ima/ima_main.c +++ b/security/integrity/ima/ima_main.c @@ -266,7 +266,7 @@ static int process_measurement(struct file *file, const struct cred *cred, if (!action) goto out; - mutex_lock(&iint->mutex); + mutex_lock_nested(&iint->mutex, func == DIGEST_LIST_CHECK); if (test_and_clear_bit(IMA_CHANGE_ATTR, &iint->atomic_flags)) /* reset appraisal flags if ima_inode_post_setattr was called */