Home
last modified time | relevance | path

Searched refs:num_roles (Results 1 – 17 of 17) 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.c116 unsigned int num_roles = 0; in sepol_user_modify() local
136 if (sepol_user_get_roles(handle, user, &roles, &num_roles) < 0) in sepol_user_modify()
160 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.c2336 unsigned i, j, num, num_roles; in write_user_decl_rules_to_cil() local
2395 num_roles = strs_num_items(role_strs); in write_user_decl_rules_to_cil()
2396 for (j=0; j<num_roles; j++) { in write_user_decl_rules_to_cil()
/external/selinux/libsepol/tests/
Dtest-expander-users.c32 …oid check_user_roles(policydb_t * p, const char *user_name, const char **role_names, int num_roles) in check_user_roles() argument
47 found = calloc(num_roles, sizeof(unsigned char)); in check_user_roles()
51 for (j = 0; j < num_roles; j++) { in check_user_roles()
59 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()
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()
38 if (num_roles == 0) { in semanage_user_roles()
44 for (i = 1; i<num_roles; i++) { in semanage_user_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()
Duser_internal.h127 unsigned int *num_roles);
132 unsigned int num_roles);
Dsemanageswig_python.i128 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/libsemanage/include/semanage/
Duser_record.h74 unsigned int *num_roles);
79 unsigned int num_roles);
/external/selinux/libsemanage/tests/
Dtest_user.c352 unsigned int num_roles = 42; in test_user_roles() local
373 &num_roles) >= 0); in test_user_roles()
374 CU_ASSERT(num_roles == 2); in test_user_roles()
/external/selinux/libsepol/cil/src/
Dcil_policy.c1587 int num_roles; in cil_users_to_policy() local
1591 num_roles = 0; in cil_users_to_policy()
1596 if (num_roles == 0) { in cil_users_to_policy()
1600 num_roles++; in cil_users_to_policy()
1603 if (num_roles > 0) { in cil_users_to_policy()
1605 if (num_roles > 1) { in cil_users_to_policy()
1612 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.h309 int num_roles; member
Dcil.c445 (*db)->num_roles = 0; in cil_db_init()