Home
last modified time | relevance | path

Searched refs:classperms (Results 1 – 14 of 14) sorted by relevance

/external/selinux/libsepol/cil/src/
Dcil_find.c178 rc = __cil_classperms_list_match_any(cp1, cmp->classperms); in __cil_classperms_list_match_any()
185 rc = __cil_classperms_list_match_any(cp1, cp->classperms); in __cil_classperms_list_match_any()
207 rc = cil_classperms_list_match_any(cmp->classperms, cpl2); in cil_classperms_list_match_any()
214 rc = cil_classperms_list_match_any(cp->classperms, cpl2); in cil_classperms_list_match_any()
221 static void __add_classes_from_classperms_list(struct cil_list *classperms, struct cil_list *class_… in __add_classes_from_classperms_list() argument
225 cil_list_for_each(curr, classperms) { in __add_classes_from_classperms_list()
234 __add_classes_from_classperms_list(cmp->classperms, class_list); in __add_classes_from_classperms_list()
240 __add_classes_from_classperms_list(cp->classperms, class_list); in __add_classes_from_classperms_list()
250 __add_classes_from_classperms_list(cmp->classperms, class_list); in __add_classes_from_map_perms()
335 if (cil_classperms_list_match_any(avrule->perms.classperms, target->perms.classperms)) { in cil_find_matching_avrule()
Dcil_reset_ast.c37 cil_reset_classperms_list(perm->classperms); in cil_reset_perm()
55 cil_reset_classperms_list(cp->classperms); in cil_reset_classpermission()
82 cil_reset_classperms_list(cps->classperms); in cil_reset_classpermissionset()
87 cil_reset_classperms_list(cm->classperms); in cil_reset_classmapping()
199 cil_reset_classperms_list(rule->perms.classperms); in cil_reset_avrule()
388 cil_reset_classperms_list(con->classperms); in cil_reset_constrain()
Dcil_write_ast.c14 static int cil_unfill_classperms_list(struct cil_list *classperms, char **out_str, int paren);
792 char *classperms = NULL; in cil_write_avrule_orig() local
816 rc = cil_unfill_classperms_list(avrule->perms.classperms, &classperms, 0); in cil_write_avrule_orig()
819 fprintf(cil_out, "(%s %s %s %s)\n", rulekind, src, tgt, classperms); in cil_write_avrule_orig()
822 free(classperms); in cil_write_avrule_orig()
978 static int cil_unfill_classperms_list(struct cil_list *classperms, char **out_str, int paren) { in cil_unfill_classperms_list() argument
986 cil_list_for_each(curr, classperms) { in cil_unfill_classperms_list()
1066 char *classperms = NULL; in cil_write_constrain() local
1071 rc = cil_unfill_classperms_list(cons->classperms, &classperms, 0); in cil_write_constrain()
1079 fprintf(cil_out, "(%s %s %s)\n", flav, classperms, expr); in cil_write_constrain()
[all …]
Dcil_internal.h366 struct cil_list *classperms; /* Only used for map perms */ member
395 struct cil_list *classperms; member
400 struct cil_list *classperms; member
406 struct cil_list *classperms; member
609 struct cil_list *classperms; member
857 struct cil_list *classperms; member
Dcil_policy.c649 static void cil_classperms_to_string(struct cil_classperms *classperms, struct cil_list *classperms… in cil_classperms_to_string() argument
655 len += strlen(DATUM(classperms->class)->fqn) + 1; in cil_classperms_to_string()
656 cil_list_for_each(i1, classperms->perms) { in cil_classperms_to_string()
666 len = strlen(DATUM(classperms->class)->fqn); in cil_classperms_to_string()
667 memcpy(curr, DATUM(classperms->class)->fqn, len); in cil_classperms_to_string()
673 cil_list_for_each(i1, classperms->perms) { in cil_classperms_to_string()
684 static void cil_classperms_to_strings(struct cil_list *classperms, struct cil_list *classperms_strs) in cil_classperms_to_strings() argument
688 cil_list_for_each(i1, classperms) { in cil_classperms_to_strings()
697 cil_classperms_to_strings(cmp->classperms, classperms_strs); in cil_classperms_to_strings()
703 cil_classperms_to_strings(cp->classperms, classperms_strs); in cil_classperms_to_strings()
[all …]
Dcil_binary.c1366 … cil_symtab_datum *src, struct cil_symtab_datum *tgt, struct cil_list *classperms, cond_node_t *co… in __cil_avrule_expand() argument
1371 cil_list_for_each(curr, classperms) { in __cil_avrule_expand()
1383 rc = __cil_avrule_expand(pdb, kind, src, tgt, cmp->classperms, cond_node, cond_flavor); in __cil_avrule_expand()
1392 rc = __cil_avrule_expand(pdb, kind, src, tgt, cp->classperms, cond_node, cond_flavor); in __cil_avrule_expand()
1427 struct cil_list *classperms = cil_avrule->perms.classperms; in __cil_avrule_to_avtab() local
1449 rc = __cil_avrule_expand(pdb, kind, src, src, classperms, cond_node, cond_flavor); in __cil_avrule_to_avtab()
1460 rc = __cil_avrule_expand(pdb, kind, src, tgt, classperms, cond_node, cond_flavor); in __cil_avrule_to_avtab()
1481 rc = __cil_avrule_expand(pdb, kind, src, tgt, classperms, cond_node, cond_flavor); in __cil_avrule_to_avtab()
1500 rc = __cil_avrule_expand(pdb, kind, src, tgt, classperms, cond_node, cond_flavor); in __cil_avrule_to_avtab()
1516 rc = __cil_avrule_expand(pdb, kind, src, tgt, classperms, cond_node, cond_flavor); in __cil_avrule_to_avtab()
[all …]
Dcil_verify.c1547 static int __cil_verify_classperms(struct cil_list *classperms, in __cil_verify_classperms() argument
1557 if (classperms == NULL) { in __cil_verify_classperms()
1582 cil_list_for_each(curr, classperms) { in __cil_verify_classperms()
1589 …rc = __cil_verify_classperms(cmp->classperms, orig, &cp->class->datum, &cmp->datum, CIL_MAP_PERM, … in __cil_verify_classperms()
1598 …rc = __cil_verify_classperms(cp->classperms, orig, NULL, &cp->datum, CIL_CLASSPERMISSION, steps, l… in __cil_verify_classperms()
1615 …return __cil_verify_classperms(cp->classperms, &cp->datum, NULL, &cp->datum, CIL_CLASSPERMISSION, … in __cil_verify_classpermission()
1629 …map_args->rc = __cil_verify_classperms(cmp->classperms, &cmp->datum, &map_args->class->datum, &cmp… in __verify_map_perm_classperms()
Dcil_copy_ast.c226 cil_copy_classperms_list(orig->classperms, &new->classperms); in cil_copy_classmapping()
287 cil_copy_classperms_list(orig->classperms, &new->classperms); in cil_copy_classpermission()
303 cil_copy_classperms_list(orig->classperms, &new->classperms); in cil_copy_classpermissionset()
828 cil_copy_classperms_list(orig->perms.classperms, &new->perms.classperms); in cil_copy_avrule()
1451 cil_copy_classperms_list(orig->classperms, &new->classperms); in cil_copy_constrain()
Dcil_tree.c666 cil_tree_print_classperms_list(cons->classperms); in cil_tree_print_constrain()
972 cil_tree_print_classperms_list(cps->classperms); in cil_tree_print_node()
993 if (cmp->classperms == NULL) { in cil_tree_print_node()
1000 cil_tree_print_classperms_list(cmp->classperms); in cil_tree_print_node()
1013 cil_tree_print_classperms_list(mapping->classperms); in cil_tree_print_node()
1195 cil_tree_print_classperms_list(rule->perms.classperms); in cil_tree_print_node()
Dcil_resolve_ast.c197 rc = cil_resolve_classperms_list(current, cp_set->set->classperms, extra_args); in cil_resolve_classperms_set()
247 rc = cil_resolve_classperms_list(current, cps->classperms, extra_args); in cil_resolve_classpermissionset()
254 if (cp->classperms == NULL) { in cil_resolve_classpermissionset()
255 cil_list_init(&cp->classperms, CIL_CLASSPERMS); in cil_resolve_classpermissionset()
258 cil_list_for_each(curr, cps->classperms) { in cil_resolve_classpermissionset()
259 cil_list_append(cp->classperms, curr->flavor, curr->data); in cil_resolve_classpermissionset()
339 rc = cil_resolve_classperms_list(current, rule->perms.classperms, extra_args); in cil_resolve_avrule()
801 rc = cil_resolve_classperms_list(current, mapping->classperms, extra_args); in cil_resolve_classmapping()
806 if (mp->classperms == NULL) { in cil_resolve_classmapping()
807 cil_list_init(&mp->classperms, CIL_CLASSPERMS); in cil_resolve_classmapping()
[all …]
Dcil_post.c2111 static int __evaluate_classperms_list(struct cil_list *classperms, struct cil_db *db) in __evaluate_classperms_list() argument
2116 cil_list_for_each(curr, classperms) { in __evaluate_classperms_list()
2128 rc = __evaluate_classperms_list(cmp->classperms, db); in __evaluate_classperms_list()
2137 rc = __evaluate_classperms_list(cp->classperms, db); in __evaluate_classperms_list()
2160 int rc = __evaluate_classperms_list(cmp->classperms, map_args->db); in __evaluate_map_perm_classperms()
2205 rc = __evaluate_classperms_list(cp->classperms, db); in __cil_post_db_classperms_helper()
2213 rc = __evaluate_classperms_list(avrule->perms.classperms, db); in __cil_post_db_classperms_helper()
2222 rc = __evaluate_classperms_list(constrain->classperms, db); in __cil_post_db_classperms_helper()
Dcil.c2556 (*constrain)->classperms = NULL; in cil_constrain_init()
2585 (*perm)->classperms = NULL; in cil_perm_init()
2593 (*cp)->classperms = NULL; in cil_classpermission_init()
2601 (*cps)->classperms = NULL; in cil_classpermissionset_init()
2626 (*mapping)->classperms = NULL; in cil_classmapping_init()
Dcil_build_ast.c547 cil_list_destroy(&perm->classperms, CIL_FALSE); in cil_destroy_perm()
793 cil_list_destroy(&cp->classperms, CIL_FALSE); in cil_destroy_classpermission()
796 cil_destroy_classperms_list(&cp->classperms); in cil_destroy_classpermission()
830 rc = cil_fill_classperms_list(parse_current->next->next, &cps->classperms); in cil_gen_classpermissionset()
852 cil_destroy_classperms_list(&cps->classperms); in cil_destroy_classpermissionset()
925 rc = cil_fill_classperms_list(parse_current->next->next->next, &mapping->classperms); in cil_gen_classmapping()
947 cil_destroy_classperms_list(&mapping->classperms); in cil_destroy_classmapping()
2053 rc = cil_fill_classperms_list(parse_current->next->next->next, &rule->perms.classperms); in cil_gen_avrule()
2076 cil_destroy_classperms_list(&rule->perms.classperms); in cil_destroy_avrule()
4008 rc = cil_fill_classperms_list(parse_current->next, &cons->classperms); in cil_gen_constrain()
[all …]
/external/selinux/libsepol/src/
Dmodule_to_cil.c559 …db *pdb, uint32_t type, const char *src, const char *tgt, const struct class_perm_node *classperms) in avrule_to_cil() argument
597 for (classperm = classperms; classperm != NULL; classperm = classperm->next) { in avrule_to_cil()
681 …t32_t type, const char *src, const char *tgt, const class_perm_node_t *classperms, const av_extend… in avrulex_to_cil() argument
706 for (classperm = classperms; classperm != NULL; classperm = classperm->next) { in avrulex_to_cil()