Searched refs:usrdatum (Results 1 – 8 of 8) sorted by relevance
/external/libsepol/src/ |
D | users.c | 21 user_datum_t *usrdatum = policydb->user_val_to_struct[user_idx]; in user_to_record() local 22 ebitmap_t *roles = &(usrdatum->roles.roles); in user_to_record() 50 &usrdatum->exp_dfltlevel) < 0) { in user_to_record() 56 &usrdatum->exp_dfltlevel) < 0) { in user_to_record() 74 if (mls_range_cpy(&context.range, &usrdatum->exp_range) < 0) { in user_to_record() 116 user_datum_t *usrdatum = NULL; in sepol_user_modify() local 137 usrdatum = hashtab_search(policydb->p_users.table, in sepol_user_modify() 141 if (usrdatum) { in sepol_user_modify() 143 int value_cp = usrdatum->s.value; in sepol_user_modify() 144 user_datum_destroy(usrdatum); in sepol_user_modify() [all …]
|
D | genusers.c | 42 user_datum_t *usrdatum; local 87 usrdatum = hashtab_search(policydb->p_users.table, q); 88 if (usrdatum) { 90 ebitmap_destroy(&usrdatum->roles.roles); 91 ebitmap_init(&usrdatum->roles.roles); 102 usrdatum = 104 if (!usrdatum) { 111 memset(usrdatum, 0, sizeof(user_datum_t)); 112 usrdatum->s.value = ++policydb->p_users.nprim; 113 ebitmap_init(&usrdatum->roles.roles); [all …]
|
D | context.c | 38 user_datum_t *usrdatum; in context_is_valid() local 65 usrdatum = p->user_val_to_struct[c->user - 1]; in context_is_valid() 66 if (!usrdatum) in context_is_valid() 69 if (!ebitmap_get_bit(&usrdatum->cache, c->role - 1)) in context_is_valid() 150 user_datum_t *usrdatum; in context_from_record() local 168 usrdatum = (user_datum_t *) hashtab_search(policydb->p_users.table, in context_from_record() 170 if (!usrdatum) { in context_from_record() 174 scontext->user = usrdatum->s.value; in context_from_record()
|
D | policydb.c | 850 user_datum_t *usrdatum; in user_index() local 852 usrdatum = (user_datum_t *) datum; in user_index() 855 if (!usrdatum->s.value || usrdatum->s.value > p->p_users.nprim) in user_index() 858 p->p_user_val_to_name[usrdatum->s.value - 1] = (char *)key; in user_index() 859 p->user_val_to_struct[usrdatum->s.value - 1] = usrdatum; in user_index() 2768 user_datum_t *usrdatum; in user_read() local 2773 usrdatum = calloc(1, sizeof(user_datum_t)); in user_read() 2774 if (!usrdatum) in user_read() 2785 usrdatum->s.value = le32_to_cpu(buf[1]); in user_read() 2787 usrdatum->bounds = le32_to_cpu(buf[2]); in user_read() [all …]
|
D | mls.c | 262 user_datum_t *usrdatum; in mls_context_isvalid() local 312 usrdatum = p->user_val_to_struct[c->user - 1]; in mls_context_isvalid() 313 if (!mls_range_contains(usrdatum->exp_range, c->range)) in mls_context_isvalid()
|
D | write.c | 1136 user_datum_t *usrdatum; in user_write() local 1143 usrdatum = (user_datum_t *) datum; in user_write() 1148 buf[items++] = cpu_to_le32(usrdatum->s.value); in user_write() 1150 buf[items++] = cpu_to_le32(usrdatum->bounds); in user_write() 1160 if (ebitmap_write(&usrdatum->roles.roles, fp)) in user_write() 1163 if (role_set_write(&usrdatum->roles, fp)) in user_write() 1175 if (mls_write_range_helper(&usrdatum->exp_range, fp)) in user_write() 1177 if (mls_write_level(&usrdatum->exp_dfltlevel, fp)) in user_write() 1183 if (mls_write_semantic_range_helper(&usrdatum->range, fp)) in user_write() 1185 if (mls_write_semantic_level_helper(&usrdatum->dfltlevel, fp)) in user_write()
|
D | services.c | 872 user_datum_t *usrdatum; in convert_context() local 883 usrdatum = (user_datum_t *) hashtab_search(args->newp->p_users.table, in convert_context() 888 if (!usrdatum) { in convert_context() 891 c->user = usrdatum->s.value; in convert_context()
|
/external/checkpolicy/ |
D | policy_define.c | 3457 user_datum_t *usrdatum; in define_user() local 3482 if ((usrdatum = declare_user()) == NULL) { in define_user() 3487 if (set_user_roles(&usrdatum->roles, id)) in define_user() 3509 usrdatum->dfltlevel.sens = levdatum->level->sens; in define_user() 3513 &usrdatum->dfltlevel.cat)) { in define_user() 3534 usrdatum->range.level[l].sens = levdatum->level->sens; in define_user() 3538 &usrdatum->range.level[l].cat)) { in define_user() 3551 if (mls_semantic_level_cpy(&usrdatum->range.level[1], in define_user() 3552 &usrdatum->range.level[0])) { in define_user() 3566 user_datum_t *usrdatum; in parse_security_context() local [all …]
|