Lines Matching refs:file
276 aa_str_perms(profile->file.dfa, profile->file.start, name, cond, perms); in __aa_path_perm()
383 state = aa_str_perms(profile->file.dfa, profile->file.start, lname, in profile_path_link()
390 state = aa_dfa_null_transition(profile->file.dfa, state); in profile_path_link()
391 aa_str_perms(profile->file.dfa, state, tname, cond, &perms); in profile_path_link()
413 aa_str_perms(profile->file.dfa, profile->file.start, tname, cond, in profile_path_link()
508 struct aa_label *flabel, struct file *file, in __file_path_perm() argument
514 .uid = i_uid_into_mnt(file_mnt_user_ns(file), file_inode(file)), in __file_path_perm()
515 .mode = file_inode(file)->i_mode in __file_path_perm()
532 profile_path_perm(op, profile, &file->f_path, buffer, in __file_path_perm()
545 profile_path_perm(op, profile, &file->f_path, in __file_path_perm()
550 profile_path_perm(op, profile, &file->f_path, in __file_path_perm()
555 update_file_ctx(file_ctx(file), label, request); in __file_path_perm()
563 struct aa_label *flabel, struct file *file, in __file_sock_perm() argument
566 struct socket *sock = (struct socket *) file->private_data; in __file_sock_perm()
583 update_file_ctx(file_ctx(file), label, request); in __file_sock_perm()
598 int aa_file_perm(const char *op, struct aa_label *label, struct file *file, in aa_file_perm() argument
607 AA_BUG(!file); in aa_file_perm()
609 fctx = file_ctx(file); in aa_file_perm()
633 if (file->f_path.mnt && path_mediated_fs(file->f_path.dentry)) in aa_file_perm()
634 error = __file_path_perm(op, label, flabel, file, request, in aa_file_perm()
637 else if (S_ISSOCK(file_inode(file)->i_mode)) in aa_file_perm()
638 error = __file_sock_perm(op, label, flabel, file, request, in aa_file_perm()
658 struct file *file; in revalidate_tty() local
662 file = file_priv->file; in revalidate_tty()
664 if (aa_file_perm(OP_INHERIT, label, file, MAY_READ | MAY_WRITE, in revalidate_tty()
675 static int match_file(const void *p, struct file *file, unsigned int fd) in match_file() argument
679 if (aa_file_perm(OP_INHERIT, label, file, aa_map_file_to_perms(file), in match_file()
690 struct file *devnull = NULL; in aa_inherit_files()