Lines Matching refs:perms

100 static void compute_fperms_allow(struct aa_perms *perms, struct aa_dfa *dfa,  in compute_fperms_allow()  argument
103 perms->allow |= AA_MAY_GETATTR; in compute_fperms_allow()
107 perms->allow |= AA_MAY_CHANGE_PROFILE; in compute_fperms_allow()
109 perms->allow |= AA_MAY_ONEXEC; in compute_fperms_allow()
115 struct aa_perms perms = { }; in compute_fperms_user() local
117 perms.allow = map_old_perms(dfa_user_allow(dfa, state)); in compute_fperms_user()
118 perms.audit = map_old_perms(dfa_user_audit(dfa, state)); in compute_fperms_user()
119 perms.quiet = map_old_perms(dfa_user_quiet(dfa, state)); in compute_fperms_user()
120 perms.xindex = dfa_user_xindex(dfa, state); in compute_fperms_user()
122 compute_fperms_allow(&perms, dfa, state); in compute_fperms_user()
124 return perms; in compute_fperms_user()
130 struct aa_perms perms = { }; in compute_fperms_other() local
132 perms.allow = map_old_perms(dfa_other_allow(dfa, state)); in compute_fperms_other()
133 perms.audit = map_old_perms(dfa_other_audit(dfa, state)); in compute_fperms_other()
134 perms.quiet = map_old_perms(dfa_other_quiet(dfa, state)); in compute_fperms_other()
135 perms.xindex = dfa_other_xindex(dfa, state); in compute_fperms_other()
137 compute_fperms_allow(&perms, dfa, state); in compute_fperms_other()
139 return perms; in compute_fperms_other()
176 struct aa_perms *perms; in compute_xmatch_perms() local
184 perms = kvcalloc(state_count, sizeof(struct aa_perms), GFP_KERNEL); in compute_xmatch_perms()
185 if (!perms) in compute_xmatch_perms()
191 perms[state].allow = dfa_user_allow(xmatch, state); in compute_xmatch_perms()
193 return perms; in compute_xmatch_perms()
213 struct aa_perms perms = { }; in compute_perms_entry() local
215 perms.allow = dfa_user_allow(dfa, state); in compute_perms_entry()
216 perms.audit = dfa_user_audit(dfa, state); in compute_perms_entry()
217 perms.quiet = dfa_user_quiet(dfa, state); in compute_perms_entry()
230 perms.allow |= map_other(dfa_other_allow(dfa, state)); in compute_perms_entry()
232 perms.allow |= AA_MAY_LOCK; in compute_perms_entry()
234 perms.allow |= map_xbits(dfa_user_xbits(dfa, state)); in compute_perms_entry()
240 perms.audit |= map_other(dfa_other_audit(dfa, state)); in compute_perms_entry()
241 perms.quiet |= map_other(dfa_other_quiet(dfa, state)); in compute_perms_entry()
243 perms.quiet |= map_xbits(dfa_other_xbits(dfa, state)); in compute_perms_entry()
245 return perms; in compute_perms_entry()
297 policy->perms = compute_xmatch_perms(policy->dfa, &policy->size); in aa_compat_map_xmatch()
298 if (!policy->perms) in aa_compat_map_xmatch()
308 policy->perms = compute_perms(policy->dfa, version, &policy->size); in aa_compat_map_policy()
309 if (!policy->perms) in aa_compat_map_policy()
319 policy->perms = compute_fperms(policy->dfa, &policy->size); in aa_compat_map_file()
320 if (!policy->perms) in aa_compat_map_file()