Skip to contentSkip to conversation

ima: re-initialize iint->atomic_flags

PATCH New Mimi Zohar 1 participant 1 message Jan 23, 2018

Subsystems (4)
lore
Share & tools
lore

Mimi Zohar

author
#0 lore raw

PATCH 1/1 ima: re-initialize iint->atomic_flags

Intermittently security.ima is not being written for new files. This patch re-initializes the new slab iint->atomic_flags field before freeing it.

Fixes commit 0d73a55208e9 ("ima: re-introduce own integrity cache lock")
---
 security/integrity/iint.c | 1 +
 1 file changed, 1 insertion(+)
security/integrity/iint.c +1 -0
index fc38ca08dbb5..9700e96ab0f0 100644
@@ -74,6 +74,7 @@ static void iint_free(struct integrity_iint_cache *iint)
 	iint->ima_hash = NULL;
 	iint->version = 0;
 	iint->flags = 0UL;
+	iint->atomic_flags = 0UL;
 	iint->ima_file_status = INTEGRITY_UNKNOWN;
 	iint->ima_mmap_status = INTEGRITY_UNKNOWN;
 	iint->ima_bprm_status = INTEGRITY_UNKNOWN;
Signature · 1 line
2.7.4