Home
last modified time | relevance | path

Searched refs:cat (Results 1 – 8 of 8) sorted by relevance

/security/selinux/ss/
Dcontext.h46 rc = ebitmap_cpy(&dst->range.level[0].cat, &src->range.level[0].cat); in mls_context_cpy()
51 rc = ebitmap_cpy(&dst->range.level[1].cat, &src->range.level[1].cat); in mls_context_cpy()
53 ebitmap_destroy(&dst->range.level[0].cat); in mls_context_cpy()
66 rc = ebitmap_cpy(&dst->range.level[0].cat, &src->range.level[0].cat); in mls_context_cpy_low()
71 rc = ebitmap_cpy(&dst->range.level[1].cat, &src->range.level[0].cat); in mls_context_cpy_low()
73 ebitmap_destroy(&dst->range.level[0].cat); in mls_context_cpy_low()
86 rc = ebitmap_cpy(&dst->range.level[0].cat, &src->range.level[1].cat); in mls_context_cpy_high()
91 rc = ebitmap_cpy(&dst->range.level[1].cat, &src->range.level[1].cat); in mls_context_cpy_high()
93 ebitmap_destroy(&dst->range.level[0].cat); in mls_context_cpy_high()
101 ebitmap_cmp(&c1->range.level[0].cat, &c2->range.level[0].cat) && in mls_context_cmp()
[all …]
Dmls.c54 e = &context->range.level[l].cat; in mls_compute_context_len()
113 e = &context->range.level[l].cat; in mls_sid_to_context()
177 return ebitmap_contains(&levdatum->level->cat, &l->cat, in mls_level_isvalid()
315 rc = ebitmap_set_bit(&context->range.level[l].cat, in mls_context_to_sid()
336 rc = ebitmap_set_bit(&context->range.level[l].cat, i, 1); in mls_context_to_sid()
361 rc = ebitmap_cpy(&context->range.level[1].cat, in mls_context_to_sid()
362 &context->range.level[0].cat); in mls_context_to_sid()
411 rc = ebitmap_cpy(&context->range.level[l].cat, in mls_range_set()
412 &range->level[l].cat); in mls_range_set()
486 ebitmap_for_each_positive_bit(&c->range.level[l].cat, node, i) { in mls_convert_context()
[all …]
Dmls_types.h23 struct ebitmap cat; /* category set */ member
33 ebitmap_cmp(&l1->cat, &l2->cat)); in mls_level_eq()
39 ebitmap_contains(&l1->cat, &l2->cat, 0)); in mls_level_dom()
Dpolicydb.c722 ebitmap_destroy(&usrdatum->range.level[0].cat); in user_destroy()
723 ebitmap_destroy(&usrdatum->range.level[1].cat); in user_destroy()
724 ebitmap_destroy(&usrdatum->dfltlevel.cat); in user_destroy()
738 ebitmap_destroy(&levdatum->level->cat); in sens_destroy()
778 ebitmap_destroy(&rt->level[0].cat); in range_tr_destroy()
779 ebitmap_destroy(&rt->level[1].cat); in range_tr_destroy()
1029 rc = ebitmap_read(&r->level[0].cat, fp); in mls_read_range_helper()
1035 rc = ebitmap_read(&r->level[1].cat, fp); in mls_read_range_helper()
1041 rc = ebitmap_cpy(&r->level[1].cat, &r->level[0].cat); in mls_read_range_helper()
1050 ebitmap_destroy(&r->level[0].cat); in mls_read_range_helper()
[all …]
Dservices.c3484 ebitmap_destroy(&ctx_new.range.level[0].cat); in security_netlbl_secattr_to_sid()
3491 ebitmap_destroy(&ctx_new.range.level[0].cat); in security_netlbl_secattr_to_sid()
/security/smack/
Dsmack_access.c494 int cat; in smk_netlbl_mls() local
500 sap->attr.mls.cat = NULL; in smk_netlbl_mls()
502 for (cat = 1, cp = catset, byte = 0; byte < len; cp++, byte++) in smk_netlbl_mls()
503 for (m = 0x80; m != 0; m >>= 1, cat++) { in smk_netlbl_mls()
506 rc = netlbl_catmap_setbit(&sap->attr.mls.cat, in smk_netlbl_mls()
507 cat, GFP_NOFS); in smk_netlbl_mls()
509 netlbl_catmap_free(sap->attr.mls.cat); in smk_netlbl_mls()
Dsmackfs.c182 static inline void smack_catset_bit(unsigned int cat, char *catsetp) in smack_catset_bit() argument
184 if (cat == 0 || cat > (SMK_CIPSOLEN * 8)) in smack_catset_bit()
187 catsetp[(cat - 1) / 8] |= 0x80 >> ((cat - 1) % 8); in smack_catset_bit()
800 struct netlbl_lsm_catmap *cmp = skp->smk_netlabel.attr.mls.cat; in cipso_seq_show()
866 unsigned int cat; in smk_set_cipso() local
926 ret = sscanf(rule, "%u", &cat); in smk_set_cipso()
927 if (ret != 1 || cat > SMACK_CIPSO_MAXCATNUM) in smk_set_cipso()
930 smack_catset_bit(cat, mapcatset); in smk_set_cipso()
935 netlbl_catmap_free(skp->smk_netlabel.attr.mls.cat); in smk_set_cipso()
936 skp->smk_netlabel.attr.mls.cat = ncats.attr.mls.cat; in smk_set_cipso()
[all …]
Dsmack_lsm.c3866 acat = netlbl_catmap_walk(sap->attr.mls.cat, in smack_from_secattr()
3869 skp->smk_netlabel.attr.mls.cat, in smack_from_secattr()