Lines Matching refs:scontext

85 				    char **scontext,
91 char **scontext,
95 struct context *scontext,
271 struct context *scontext, in constraint_expr_eval() argument
305 val1 = scontext->user; in constraint_expr_eval()
309 val1 = scontext->type; in constraint_expr_eval()
313 val1 = scontext->role; in constraint_expr_eval()
337 l1 = &(scontext->range.level[0]); in constraint_expr_eval()
341 l1 = &(scontext->range.level[0]); in constraint_expr_eval()
345 l1 = &(scontext->range.level[1]); in constraint_expr_eval()
349 l1 = &(scontext->range.level[1]); in constraint_expr_eval()
353 l1 = &(scontext->range.level[0]); in constraint_expr_eval()
354 l2 = &(scontext->range.level[1]); in constraint_expr_eval()
402 c = scontext; in constraint_expr_eval()
462 struct context *scontext, in security_dump_masked_av() argument
497 if (context_struct_to_string(policydb, scontext, in security_dump_masked_av()
539 struct context *scontext, in type_attribute_bounds_av() argument
551 source = policydb->type_val_to_struct[scontext->type - 1]; in type_attribute_bounds_av()
562 memcpy(&lo_scontext, scontext, sizeof(lo_scontext)); in type_attribute_bounds_av()
586 security_dump_masked_av(policydb, scontext, tcontext, in type_attribute_bounds_av()
618 struct context *scontext, in context_struct_compute_av() argument
655 sattr = &policydb->type_attr_map_array[scontext->type - 1]; in context_struct_compute_av()
689 !constraint_expr_eval(policydb, scontext, tcontext, NULL, in context_struct_compute_av()
703 scontext->role != tcontext->role) { in context_struct_compute_av()
705 if (scontext->role == ra->role && in context_struct_compute_av()
718 type_attribute_bounds_av(policydb, scontext, tcontext, in context_struct_compute_av()
1024 struct context *scontext, *tcontext; in security_compute_xperms_decision() local
1045 scontext = sidtab_search(sidtab, ssid); in security_compute_xperms_decision()
1046 if (!scontext) { in security_compute_xperms_decision()
1074 sattr = &policydb->type_attr_map_array[scontext->type - 1]; in security_compute_xperms_decision()
1121 struct context *scontext = NULL, *tcontext = NULL; in security_compute_av() local
1133 scontext = sidtab_search(sidtab, ssid); in security_compute_av()
1134 if (!scontext) { in security_compute_av()
1141 if (ebitmap_get_bit(&policydb->permissive_map, scontext->type)) in security_compute_av()
1157 context_struct_compute_av(policydb, scontext, tcontext, tclass, avd, in security_compute_av()
1178 struct context *scontext = NULL, *tcontext = NULL; in security_compute_av_user() local
1189 scontext = sidtab_search(sidtab, ssid); in security_compute_av_user()
1190 if (!scontext) { in security_compute_av_user()
1197 if (ebitmap_get_bit(&policydb->permissive_map, scontext->type)) in security_compute_av_user()
1213 context_struct_compute_av(policydb, scontext, tcontext, tclass, avd, in security_compute_av_user()
1232 char **scontext, u32 *scontext_len) in context_struct_to_string() argument
1236 if (scontext) in context_struct_to_string()
1237 *scontext = NULL; in context_struct_to_string()
1242 if (scontext) { in context_struct_to_string()
1243 *scontext = kstrdup(context->str, GFP_ATOMIC); in context_struct_to_string()
1244 if (!(*scontext)) in context_struct_to_string()
1256 if (!scontext) in context_struct_to_string()
1263 *scontext = scontextp; in context_struct_to_string()
1283 char **scontext, u32 *scontext_len) in sidtab_entry_to_string() argument
1285 int rc = sidtab_sid2str_get(sidtab, entry, scontext, scontext_len); in sidtab_entry_to_string()
1290 rc = context_struct_to_string(p, &entry->context, scontext, in sidtab_entry_to_string()
1292 if (!rc && scontext) in sidtab_entry_to_string()
1293 sidtab_sid2str_put(sidtab, entry, *scontext, *scontext_len); in sidtab_entry_to_string()
1326 u32 sid, char **scontext, in security_sid_to_context_core() argument
1336 if (scontext) in security_sid_to_context_core()
1337 *scontext = NULL; in security_sid_to_context_core()
1348 if (!scontext) in security_sid_to_context_core()
1353 *scontext = scontextp; in security_sid_to_context_core()
1378 rc = sidtab_entry_to_string(policydb, sidtab, entry, scontext, in security_sid_to_context_core()
1399 u32 sid, char **scontext, u32 *scontext_len) in security_sid_to_context() argument
1401 return security_sid_to_context_core(state, sid, scontext, in security_sid_to_context()
1406 char **scontext, u32 *scontext_len) in security_sid_to_context_force() argument
1408 return security_sid_to_context_core(state, sid, scontext, in security_sid_to_context_force()
1427 char **scontext, u32 *scontext_len) in security_sid_to_context_inval() argument
1429 return security_sid_to_context_core(state, sid, scontext, in security_sid_to_context_inval()
1438 char *scontext, in string_to_context_struct() argument
1453 scontextp = scontext; in string_to_context_struct()
1515 const char *scontext, u32 scontext_len, in security_context_to_sid_core() argument
1531 scontext2 = kmemdup_nul(scontext, scontext_len, gfp_flags); in security_context_to_sid_core()
1604 const char *scontext, u32 scontext_len, u32 *sid, in security_context_to_sid() argument
1607 return security_context_to_sid_core(state, scontext, scontext_len, in security_context_to_sid()
1612 const char *scontext, u32 *sid, gfp_t gfp) in security_context_str_to_sid() argument
1614 return security_context_to_sid(state, scontext, strlen(scontext), in security_context_str_to_sid()
1639 const char *scontext, u32 scontext_len, in security_context_to_sid_default() argument
1642 return security_context_to_sid_core(state, scontext, scontext_len, in security_context_to_sid_default()
1647 const char *scontext, u32 scontext_len, in security_context_to_sid_force() argument
1650 return security_context_to_sid_core(state, scontext, scontext_len, in security_context_to_sid_force()
1736 struct context *scontext, *tcontext, newcontext; in security_compute_sid() local
1792 scontext = &sentry->context; in security_compute_sid()
1807 newcontext.user = scontext->user; in security_compute_sid()
1818 newcontext.role = scontext->role; in security_compute_sid()
1823 newcontext.role = scontext->role; in security_compute_sid()
1830 newcontext.type = scontext->type; in security_compute_sid()
1836 newcontext.type = scontext->type; in security_compute_sid()
1844 avkey.source_type = scontext->type; in security_compute_sid()
1868 filename_compute_type(policydb, &newcontext, scontext->type, in security_compute_sid()
1876 .role = scontext->role, in security_compute_sid()
1888 rc = mls_compute_sid(policydb, scontext, tcontext, tclass, specified, in security_compute_sid()