Home
last modified time | relevance | path

Searched refs:iint (Results 1 – 11 of 11) sorted by relevance

/kernel/linux/linux-5.10/security/integrity/
Diint.c35 struct integrity_iint_cache *iint; in __integrity_iint_find() local
39 iint = rb_entry(n, struct integrity_iint_cache, rb_node); in __integrity_iint_find()
41 if (inode < iint->inode) in __integrity_iint_find()
43 else if (inode > iint->inode) in __integrity_iint_find()
51 return iint; in __integrity_iint_find()
59 struct integrity_iint_cache *iint; in integrity_iint_find() local
65 iint = __integrity_iint_find(inode); in integrity_iint_find()
68 return iint; in integrity_iint_find()
71 static void iint_free(struct integrity_iint_cache *iint) in iint_free() argument
73 kfree(iint->ima_hash); in iint_free()
[all …]
DMakefile8 integrity-y := iint.o
/kernel/linux/linux-5.10/security/integrity/ima/
Dima_appraise.c79 struct integrity_iint_cache *iint) in ima_fix_xattr() argument
82 u8 algo = iint->ima_hash->algo; in ima_fix_xattr()
86 iint->ima_hash->xattr.sha1.type = IMA_XATTR_DIGEST; in ima_fix_xattr()
89 iint->ima_hash->xattr.ng.type = IMA_XATTR_DIGEST_NG; in ima_fix_xattr()
90 iint->ima_hash->xattr.ng.algo = algo; in ima_fix_xattr()
93 &iint->ima_hash->xattr.data[offset], in ima_fix_xattr()
94 (sizeof(iint->ima_hash->xattr) - offset) + in ima_fix_xattr()
95 iint->ima_hash->length, 0); in ima_fix_xattr()
100 enum integrity_status ima_get_cache_status(struct integrity_iint_cache *iint, in ima_get_cache_status() argument
105 return iint->ima_mmap_status; in ima_get_cache_status()
[all …]
Dima_main.c111 struct integrity_iint_cache *iint, in ima_rdwr_violation_check() argument
123 if (!iint) in ima_rdwr_violation_check()
124 iint = integrity_iint_find(inode); in ima_rdwr_violation_check()
126 if (iint && test_bit(IMA_MUST_MEASURE, in ima_rdwr_violation_check()
127 &iint->atomic_flags)) in ima_rdwr_violation_check()
132 set_bit(IMA_MUST_MEASURE, &iint->atomic_flags); in ima_rdwr_violation_check()
143 ima_add_violation(file, *pathname, iint, in ima_rdwr_violation_check()
146 ima_add_violation(file, *pathname, iint, in ima_rdwr_violation_check()
150 static void ima_check_last_writer(struct integrity_iint_cache *iint, in ima_check_last_writer() argument
159 mutex_lock(&iint->mutex); in ima_check_last_writer()
[all …]
Dima_api.c134 struct integrity_iint_cache *iint, in ima_add_violation() argument
139 struct ima_event_data event_data = { .iint = iint, in ima_add_violation()
209 int ima_collect_measurement(struct integrity_iint_cache *iint, in ima_collect_measurement() argument
233 if (iint->flags & IMA_COLLECTED) in ima_collect_measurement()
256 tmpbuf = krealloc(iint->ima_hash, length, GFP_NOFS); in ima_collect_measurement()
262 iint->ima_hash = tmpbuf; in ima_collect_measurement()
263 memcpy(iint->ima_hash, &hash, length); in ima_collect_measurement()
264 iint->version = i_version; in ima_collect_measurement()
268 iint->flags |= IMA_COLLECTED; in ima_collect_measurement()
296 void ima_store_measurement(struct integrity_iint_cache *iint, in ima_store_measurement() argument
[all …]
Dima_init.c45 struct integrity_iint_cache tmp_iint, *iint = &tmp_iint; in ima_add_boot_aggregate() local
46 struct ima_event_data event_data = { .iint = iint, in ima_add_boot_aggregate()
55 memset(iint, 0, sizeof(*iint)); in ima_add_boot_aggregate()
57 iint->ima_hash = &hash.hdr; in ima_add_boot_aggregate()
58 iint->ima_hash->algo = ima_hash_algo; in ima_add_boot_aggregate()
59 iint->ima_hash->length = hash_digest_size[ima_hash_algo]; in ima_add_boot_aggregate()
Dima.h64 struct integrity_iint_cache *iint; member
150 struct integrity_iint_cache *iint,
260 int ima_collect_measurement(struct integrity_iint_cache *iint,
263 void ima_store_measurement(struct integrity_iint_cache *iint, struct file *file,
271 void ima_audit_measurement(struct integrity_iint_cache *iint,
308 int ima_check_blacklist(struct integrity_iint_cache *iint,
311 struct integrity_iint_cache *iint,
316 void ima_update_xattr(struct integrity_iint_cache *iint, struct file *file);
317 enum integrity_status ima_get_cache_status(struct integrity_iint_cache *iint,
325 static inline int ima_check_blacklist(struct integrity_iint_cache *iint, in ima_check_blacklist() argument
[all …]
Dima_template_lib.c283 if (ima_template_hash_algo_allowed(event_data->iint->ima_hash->algo)) { in ima_eventdigest_init()
284 cur_digest = event_data->iint->ima_hash->digest; in ima_eventdigest_init()
285 cur_digestsize = event_data->iint->ima_hash->length; in ima_eventdigest_init()
339 cur_digest = event_data->iint->ima_hash->digest; in ima_eventdigest_ng_init()
340 cur_digestsize = event_data->iint->ima_hash->length; in ima_eventdigest_ng_init()
342 hash_algo = event_data->iint->ima_hash->algo; in ima_eventdigest_ng_init()
/kernel/linux/linux-5.10/security/integrity/evm/
Devm_main.c133 struct integrity_iint_cache *iint) in evm_verify_hmac() argument
142 if (iint && (iint->evm_status == INTEGRITY_PASS || in evm_verify_hmac()
143 iint->evm_status == INTEGRITY_PASS_IMMUTABLE)) in evm_verify_hmac()
144 return iint->evm_status; in evm_verify_hmac()
206 if (iint) in evm_verify_hmac()
207 iint->flags |= EVM_IMMUTABLE_DIGSIG; in evm_verify_hmac()
227 if (iint) in evm_verify_hmac()
228 iint->evm_status = evm_status; in evm_verify_hmac()
276 struct integrity_iint_cache *iint) in evm_verifyxattr() argument
281 if (!iint) { in evm_verifyxattr()
[all …]
Devm_crypto.c270 struct integrity_iint_cache *iint; in evm_is_immutable() local
273 iint = integrity_iint_find(inode); in evm_is_immutable()
274 if (iint && (iint->flags & EVM_IMMUTABLE_DIGSIG)) in evm_is_immutable()
/kernel/linux/linux-5.10/include/linux/
Devm.h23 struct integrity_iint_cache *iint);
58 struct integrity_iint_cache *iint) in evm_verifyxattr() argument