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()
177 struct aa_perms *perms; in compute_xmatch_perms() local
185 perms = kvcalloc(state_count, sizeof(struct aa_perms), GFP_KERNEL); in compute_xmatch_perms()
186 if (!perms) in compute_xmatch_perms()
192 perms[state].allow = dfa_user_allow(xmatch, state); in compute_xmatch_perms()
194 return perms; in compute_xmatch_perms()
214 struct aa_perms perms = { }; in compute_perms_entry() local
216 perms.allow = dfa_user_allow(dfa, state); in compute_perms_entry()
217 perms.audit = dfa_user_audit(dfa, state); in compute_perms_entry()
218 perms.quiet = dfa_user_quiet(dfa, state); in compute_perms_entry()
231 perms.allow |= map_other(dfa_other_allow(dfa, state)); in compute_perms_entry()
233 perms.allow |= AA_MAY_LOCK; in compute_perms_entry()
235 perms.allow |= map_xbits(dfa_user_xbits(dfa, state)); in compute_perms_entry()
241 perms.audit |= map_other(dfa_other_audit(dfa, state)); in compute_perms_entry()
242 perms.quiet |= map_other(dfa_other_quiet(dfa, state)); in compute_perms_entry()
244 perms.quiet |= map_xbits(dfa_other_xbits(dfa, state)); in compute_perms_entry()
246 return perms; in compute_perms_entry()
298 policy->perms = compute_xmatch_perms(policy->dfa, &policy->size); in aa_compat_map_xmatch()
299 if (!policy->perms) in aa_compat_map_xmatch()
309 policy->perms = compute_perms(policy->dfa, version, &policy->size); in aa_compat_map_policy()
310 if (!policy->perms) in aa_compat_map_policy()
320 policy->perms = compute_fperms(policy->dfa, &policy->size); in aa_compat_map_file()
321 if (!policy->perms) in aa_compat_map_file()