Lines Matching refs:policydb
9 static void retrieve_mapping(policydb_t *policydb, struct type_datum *dat, char *name, int reverse)… in retrieve_mapping() argument
14 ebitmap_for_each_bit(&policydb->type_attr_map[dat->s.value - 1], n, bit) { in retrieve_mapping()
17 if (!strcmp(policydb->p_type_val_to_name[bit], name)) in retrieve_mapping()
19 printf("%s\n", policydb->p_type_val_to_name[bit]); in retrieve_mapping()
22 ebitmap_for_each_bit(&policydb->attr_type_map[dat->s.value - 1], n, bit) { in retrieve_mapping()
25 printf("%s\n", policydb->p_type_val_to_name[bit]); in retrieve_mapping()
30 static int list_attribute(policydb_t *policydb, char *name, int reverse) in list_attribute() argument
34 dat = hashtab_search(policydb->p_types.table, name); in list_attribute()
51 retrieve_mapping(policydb, dat, name, reverse); in list_attribute()
70 static int list_all_attributes(policydb_t *policydb) { in list_all_attributes() argument
71 return hashtab_map(policydb->p_types.table, print_attr, policydb); in list_all_attributes()
74 int attribute_func (int argc, char **argv, policydb_t *policydb) { in attribute_func() argument
105 rc = list_all_attributes(policydb); in attribute_func()
107 rc = list_attribute(policydb, argv[optind], reverse); in attribute_func()