• Home
  • Raw
  • Download

Lines Matching refs:policydb

71 static policydb_t mypolicydb, *policydb = &mypolicydb;  variable
81 policydb = p; in sepol_set_policydb()
103 policydb = &mypolicydb; in sepol_set_policydb_from_file()
170 r1 = policydb->role_val_to_struct[val1 - 1]; in constraint_expr_eval()
171 r2 = policydb->role_val_to_struct[val2 - 1]; in constraint_expr_eval()
323 if (!tclass || tclass > policydb->p_classes.nprim) { in context_struct_compute_av()
327 tclass_datum = policydb->class_val_to_struct[tclass - 1]; in context_struct_compute_av()
345 sattr = &policydb->type_attr_map[scontext->type - 1]; in context_struct_compute_av()
346 tattr = &policydb->type_attr_map[tcontext->type - 1]; in context_struct_compute_av()
356 avtab_search_node(&policydb->te_avtab, &avkey); in context_struct_compute_av()
370 cond_compute_av(&policydb->te_cond_avtab, &avkey, avd); in context_struct_compute_av()
408 for (ra = policydb->role_allow; ra; ra = ra->next) { in context_struct_compute_av()
437 if (!tclass || tclass > policydb->p_classes.nprim) { in sepol_validate_transition()
441 tclass_datum = policydb->class_val_to_struct[tclass - 1]; in sepol_validate_transition()
533 rc = context_to_string(NULL, policydb, context, scontext, scontext_len); in sepol_sid_to_context()
550 if (context_from_string(NULL, policydb, &context, in sepol_context_to_sid()
586 context_to_string(NULL, policydb, scontext, &s, &slen); in compute_sid_handle_invalid_context()
587 context_to_string(NULL, policydb, tcontext, &t, &tlen); in compute_sid_handle_invalid_context()
588 context_to_string(NULL, policydb, newcontext, &n, &nlen); in compute_sid_handle_invalid_context()
591 n, s, t, policydb->p_class_val_to_name[tclass - 1]); in compute_sid_handle_invalid_context()
658 avdatum = avtab_search(&policydb->te_avtab, &avkey); in sepol_compute_sid()
662 node = avtab_search_node(&policydb->te_cond_avtab, &avkey); in sepol_compute_sid()
682 for (roletr = policydb->role_tr; roletr; in sepol_compute_sid()
699 rc = mls_compute_sid(policydb, scontext, tcontext, tclass, specified, in sepol_compute_sid()
705 if (!policydb_context_isvalid(policydb, &newcontext)) { in sepol_compute_sid()
846 context_to_string(NULL, policydb, context, &s, &len); in convert_context_handle_invalid_context()
926 context_to_string(NULL, policydb, &oldc, &s, &len); in convert_context()
1028 (policydb->p_classes.table, validate_class, &newpolicydb)) { in sepol_load_policy()
1043 args.oldp = policydb; in sepol_load_policy()
1048 memcpy(&oldpolicydb, policydb, sizeof *policydb); in sepol_load_policy()
1052 memcpy(policydb, &newpolicydb, sizeof *policydb); in sepol_load_policy()
1082 c = policydb->ocontexts[OCON_FS]; in sepol_fs_sid()
1125 c = policydb->ocontexts[OCON_PORT]; in sepol_port_sid()
1164 c = policydb->ocontexts[OCON_NETIF]; in sepol_netif_sid()
1233 c = policydb->ocontexts[OCON_NODE]; in sepol_node_sid()
1248 c = policydb->ocontexts[OCON_NODE6]; in sepol_node_sid()
1308 user = (user_datum_t *) hashtab_search(policydb->p_users.table, in sepol_get_user_sids()
1326 role = policydb->role_val_to_struct[i]; in sepol_get_user_sids()
1336 (fromcon, user, &usercon, policydb->mls)) in sepol_get_user_sids()
1397 for (genfs = policydb->genfs; genfs; genfs = genfs->next) { in sepol_genfs_sid()
1440 c = policydb->ocontexts[OCON_FSUSE]; in sepol_fs_use()