Home
last modified time | relevance | path

Searched refs:num_roles (Results 1 – 16 of 16) sorted by relevance

/external/selinux/libsepol/src/
Duser_record.c22 unsigned int num_roles; member
175 return user->num_roles; in hidden_def()
193 sizeof(char *) * (user->num_roles + 1)); in sepol_user_add_role()
197 user->num_roles++; in sepol_user_add_role()
199 user->roles[user->num_roles - 1] = role_cp; in sepol_user_add_role()
217 for (i = 0; i < user->num_roles; i++) in hidden_def()
227 const char **roles_arr, unsigned int num_roles) in hidden_def()
233 if (num_roles > 0) { in hidden_def()
236 tmp_roles = (char **)calloc(1, sizeof(char *) * num_roles); in hidden_def()
240 for (i = 0; i < num_roles; i++) { in hidden_def()
[all …]
Dusers.c118 unsigned int num_roles = 0; in sepol_user_modify() local
138 if (sepol_user_get_roles(handle, user, &roles, &num_roles) < 0) in sepol_user_modify()
162 for (i = 0; i < num_roles; i++) { in sepol_user_modify()
Dmodule_to_cil.c1485 int num_roles = 0; in role_allows_to_cil() local
1493 rc = process_roleset(pdb, rs, attr_list, &roles, &num_roles); in role_allows_to_cil()
1504 for (i = 0; i < num_roles; i++) { in role_allows_to_cil()
1510 names_destroy(&roles, &num_roles); in role_allows_to_cil()
1517 names_destroy(&roles, &num_roles); in role_allows_to_cil()
Dkernel_to_cil.c2321 unsigned i, j, num, num_roles; in write_user_decl_rules_to_cil() local
2380 num_roles = strs_num_items(role_strs); in write_user_decl_rules_to_cil()
2381 for (j=0; j<num_roles; j++) { in write_user_decl_rules_to_cil()
/external/selinux/libsepol/tests/
Dtest-expander-users.c31 …oid check_user_roles(policydb_t * p, const char *user_name, const char **role_names, int num_roles) in check_user_roles() argument
46 found = calloc(num_roles, sizeof(unsigned char)); in check_user_roles()
51 for (j = 0; j < num_roles; j++) { in check_user_roles()
60 for (j = 0; j < num_roles; j++) { in check_user_roles()
/external/selinux/libsemanage/src/
Duser_base_record.c137 unsigned int *num_roles) in semanage_user_base_get_roles() argument
140 return sepol_user_get_roles(handle->sepolh, user, roles_arr, num_roles); in semanage_user_base_get_roles()
146 unsigned int num_roles) in semanage_user_base_set_roles() argument
149 return sepol_user_set_roles(handle->sepolh, user, roles_arr, num_roles); in semanage_user_base_set_roles()
Duser_record.c210 const char ***roles_arr, unsigned int *num_roles) in semanage_user_get_roles() argument
214 num_roles); in semanage_user_get_roles()
221 const char **roles_arr, unsigned int num_roles) in hidden_def()
225 num_roles); in hidden_def()
Dseusers_local.c23 unsigned int num_roles; in semanage_user_roles() local
34 &num_roles) >= 0) { in semanage_user_roles()
35 for (i = 0; i<num_roles; i++) { in semanage_user_roles()
41 for (i = 1; i<num_roles; i++) { in semanage_user_roles()
Duser_internal.h127 unsigned int *num_roles);
132 unsigned int num_roles);
Dsemanageswig_python.i128 unsigned int* num_roles) {
/external/selinux/libsemanage/include/semanage/
Duser_record.h74 unsigned int *num_roles);
79 unsigned int num_roles);
/external/selinux/libsepol/include/sepol/
Duser_record.h65 unsigned int *num_roles);
69 const char **roles_arr, unsigned int num_roles);
/external/selinux/libsepol/cil/src/
Dcil_policy.c1590 int num_roles; in cil_users_to_policy() local
1594 num_roles = 0; in cil_users_to_policy()
1599 if (num_roles == 0) { in cil_users_to_policy()
1603 num_roles++; in cil_users_to_policy()
1606 if (num_roles > 0) { in cil_users_to_policy()
1608 if (num_roles > 1) { in cil_users_to_policy()
1615 if (num_roles > 1) { in cil_users_to_policy()
Dcil_post.c597 role->value = db->num_roles; in __cil_post_db_count_helper()
598 db->num_roles++; in __cil_post_db_count_helper()
685 db->val_to_role = cil_malloc(sizeof(*db->val_to_role) * db->num_roles); in __cil_post_db_array_helper()
965 rc = __cil_expr_list_to_bitmap(attr->expr_list, attr->roles, db->num_roles, db); in __evaluate_role_expression()
Dcil_internal.h307 int num_roles; member
Dcil.c281 (*db)->num_roles = 0; in cil_db_init()