Lines Matching refs:profile
105 int aa_audit_file(struct aa_profile *profile, struct aa_perms *perms, in aa_audit_file() argument
126 if (unlikely(AUDIT_MODE(profile) == AUDIT_ALL)) in aa_audit_file()
145 AUDIT_MODE(profile) != AUDIT_NOQUIET && in aa_audit_file()
146 AUDIT_MODE(profile) != AUDIT_ALL) in aa_audit_file()
154 return aa_audit(type, profile, &sa, file_audit_cb); in aa_audit_file()
174 struct aa_profile *profile; in path_name() local
181 fn_for_each_confined(label, profile, in path_name()
182 aa_audit_file(profile, &nullperms, op, request, *name, in path_name()
281 int __aa_path_perm(const char *op, struct aa_profile *profile, const char *name, in __aa_path_perm() argument
287 if (profile_unconfined(profile)) in __aa_path_perm()
289 aa_str_perms(profile->file.dfa, profile->file.start, name, cond, perms); in __aa_path_perm()
292 return aa_audit_file(profile, perms, op, request, name, NULL, NULL, in __aa_path_perm()
297 static int profile_path_perm(const char *op, struct aa_profile *profile, in profile_path_perm() argument
305 if (profile_unconfined(profile)) in profile_path_perm()
308 error = path_name(op, &profile->label, path, in profile_path_perm()
309 flags | profile->path_flags, buffer, &name, cond, in profile_path_perm()
313 return __aa_path_perm(op, profile, name, request, cond, flags, in profile_path_perm()
333 struct aa_profile *profile; in aa_path_perm() local
340 error = fn_for_each_confined(label, profile, in aa_path_perm()
341 profile_path_perm(op, profile, path, buffer, request, in aa_path_perm()
369 static int profile_path_link(struct aa_profile *profile, in profile_path_link() argument
381 error = path_name(OP_LINK, &profile->label, link, profile->path_flags, in profile_path_link()
387 error = path_name(OP_LINK, &profile->label, target, profile->path_flags, in profile_path_link()
394 state = aa_str_perms(profile->file.dfa, profile->file.start, lname, in profile_path_link()
401 state = aa_dfa_null_transition(profile->file.dfa, state); in profile_path_link()
402 aa_str_perms(profile->file.dfa, state, tname, cond, &perms); in profile_path_link()
424 aa_str_perms(profile->file.dfa, profile->file.start, tname, cond, in profile_path_link()
446 return aa_audit_file(profile, &lperms, OP_LINK, request, lname, tname, in profile_path_link()
478 struct aa_profile *profile; in aa_path_link() local
483 error = fn_for_each_confined(label, profile, in aa_path_link()
484 profile_path_link(profile, &link, buffer, &target, in aa_path_link()
516 struct aa_profile *profile; in __file_path_perm() local
534 error = fn_for_each_not_in_set(flabel, label, profile, in __file_path_perm()
535 profile_path_perm(op, profile, &file->f_path, buffer, in __file_path_perm()
547 error = fn_for_each(label, profile, in __file_path_perm()
548 profile_path_perm(op, profile, &file->f_path, in __file_path_perm()
552 error = fn_for_each_not_in_set(label, flabel, profile, in __file_path_perm()
553 profile_path_perm(op, profile, &file->f_path, in __file_path_perm()