Lines Matching full:ab
66 * @ab: Supplies a pointer to the audit_buffer to append to.
69 static void audit_dmv_roothash(struct audit_buffer *ab, const void *rh) in audit_dmv_roothash() argument
71 audit_log_format(ab, "%s", audit_prop_names[IPE_PROP_DMV_ROOTHASH]); in audit_dmv_roothash()
72 ipe_digest_audit(ab, rh); in audit_dmv_roothash()
77 * @ab: Supplies a pointer to the audit_buffer to append to.
80 static void audit_fsv_digest(struct audit_buffer *ab, const void *d) in audit_fsv_digest() argument
82 audit_log_format(ab, "%s", audit_prop_names[IPE_PROP_FSV_DIGEST]); in audit_fsv_digest()
83 ipe_digest_audit(ab, d); in audit_fsv_digest()
88 * @ab: Supplies a pointer to the audit_buffer to append to.
91 static void audit_rule(struct audit_buffer *ab, const struct ipe_rule *r) in audit_rule() argument
95 audit_log_format(ab, " rule=\"op=%s ", audit_op_names[r->op]); in audit_rule()
100 audit_dmv_roothash(ab, ptr->value); in audit_rule()
103 audit_fsv_digest(ab, ptr->value); in audit_rule()
106 audit_log_format(ab, "%s", audit_prop_names[ptr->type]); in audit_rule()
110 audit_log_format(ab, " "); in audit_rule()
113 audit_log_format(ab, "action=%s\"", ACTSTR(r->action)); in audit_rule()
131 struct audit_buffer *ab; in ipe_audit_match() local
137 ab = audit_log_start(audit_context(), GFP_ATOMIC | __GFP_NOWARN, in ipe_audit_match()
139 if (!ab) in ipe_audit_match()
142 audit_log_format(ab, "ipe_op=%s ipe_hook=%s enforcing=%d pid=%d comm=", in ipe_audit_match()
145 audit_log_untrustedstring(ab, get_task_comm(comm, current)); in ipe_audit_match()
148 audit_log_d_path(ab, " path=", &ctx->file->f_path); in ipe_audit_match()
151 audit_log_format(ab, " dev="); in ipe_audit_match()
152 audit_log_untrustedstring(ab, inode->i_sb->s_id); in ipe_audit_match()
153 audit_log_format(ab, " ino=%lu", inode->i_ino); in ipe_audit_match()
155 audit_log_format(ab, " dev=? ino=?"); in ipe_audit_match()
158 audit_log_format(ab, " path=? dev=? ino=?"); in ipe_audit_match()
162 audit_rule(ab, r); in ipe_audit_match()
164 audit_log_format(ab, " rule=\"DEFAULT op=%s action=%s\"", op, in ipe_audit_match()
167 audit_log_format(ab, " rule=\"DEFAULT action=%s\"", in ipe_audit_match()
170 audit_log_end(ab); in ipe_audit_match()
174 * audit_policy() - Audit a policy's name, version and thumbprint to @ab.
175 * @ab: Supplies a pointer to the audit buffer to append to.
179 static void audit_policy(struct audit_buffer *ab, in audit_policy() argument
206 audit_log_format(ab, audit_format, p->parsed->name, in audit_policy()
209 audit_log_n_hex(ab, digest, crypto_shash_digestsize(tfm)); in audit_policy()
224 struct audit_buffer *ab; in ipe_audit_policy_activation() local
226 ab = audit_log_start(audit_context(), GFP_KERNEL, in ipe_audit_policy_activation()
228 if (!ab) in ipe_audit_policy_activation()
232 audit_policy(ab, AUDIT_OLD_ACTIVE_POLICY_FMT, op); in ipe_audit_policy_activation()
233 audit_log_format(ab, " "); in ipe_audit_policy_activation()
239 audit_log_format(ab, AUDIT_OLD_ACTIVE_POLICY_NULL_FMT); in ipe_audit_policy_activation()
240 audit_log_format(ab, " "); in ipe_audit_policy_activation()
242 audit_policy(ab, AUDIT_NEW_ACTIVE_POLICY_FMT, np); in ipe_audit_policy_activation()
243 audit_log_format(ab, " auid=%u ses=%u lsm=ipe res=1", in ipe_audit_policy_activation()
247 audit_log_end(ab); in ipe_audit_policy_activation()
256 struct audit_buffer *ab; in ipe_audit_policy_load() local
258 ab = audit_log_start(audit_context(), GFP_KERNEL, in ipe_audit_policy_load()
260 if (!ab) in ipe_audit_policy_load()
263 audit_policy(ab, AUDIT_POLICY_LOAD_FMT, p); in ipe_audit_policy_load()
264 audit_log_format(ab, " auid=%u ses=%u lsm=ipe res=1", in ipe_audit_policy_load()
268 audit_log_end(ab); in ipe_audit_policy_load()
278 struct audit_buffer *ab; in ipe_audit_enforce() local
280 ab = audit_log_start(audit_context(), GFP_KERNEL, AUDIT_MAC_STATUS); in ipe_audit_enforce()
281 if (!ab) in ipe_audit_enforce()
291 audit_log_end(ab); in ipe_audit_enforce()