/third_party/selinux/libselinux/src/ |
D | mapping.c | 23 access_vector_t perms[sizeof(access_vector_t) * 8]; member 83 while (p_in->perms[k]) { in selinux_set_mapping() 85 if (!*p_in->perms[k]) { in selinux_set_mapping() 89 p_out->perms[k] = string_to_av_perm(p_out->value, in selinux_set_mapping() 90 p_in->perms[k]); in selinux_set_mapping() 91 if (!p_out->perms[k]) { in selinux_set_mapping() 94 p_in->perms[k], p_in->name); in selinux_set_mapping() 148 kperm |= current_mapping[tclass].perms[i]; in unmap_perm() 193 if (kperm & current_mapping[tclass].perms[i]) { in map_perm() 195 kperm &= ~current_mapping[tclass].perms[i]; in map_perm() [all …]
|
D | avc.c | 43 security_class_t tclass, access_vector_t perms, 49 access_vector_t perms; member 912 access_vector_t perms, in avc_add_callback() argument 916 security_class_t tclass, access_vector_t perms) in avc_add_callback() 932 c->perms = perms; in avc_add_callback() 945 access_vector_t perms) in avc_update_node() argument 949 node->ae.avd.allowed |= perms; in avc_update_node() 953 node->ae.avd.allowed &= ~perms; in avc_update_node() 956 node->ae.avd.auditallow |= perms; in avc_update_node() 959 node->ae.avd.auditallow &= ~perms; in avc_update_node() [all …]
|
D | stringrep.c | 25 char **perms; member 75 node->perms = calloc(MAXVECTORS,sizeof(char*)); in discover_class() 76 if (node->perms == NULL) in discover_class() 147 node->perms[value-1] = strdup(dentry->d_name); in discover_class() 148 if (node->perms[value-1] == NULL) in discover_class() 163 free(node->perms[i]); in discover_class() 167 free(node->perms); in discover_class() 182 free(cur->perms[i]); in selinux_flush_class_cache() 184 free(cur->perms); in selinux_flush_class_cache() 242 for (i = 0; i < MAXVECTORS && node->perms[i] != NULL; i++) in string_to_av_perm() [all …]
|
D | avc_internal.h | 166 security_class_t tclass, access_vector_t perms, 170 access_vector_t perms, uint32_t seqno, 173 security_class_t tclass, access_vector_t perms, 177 security_class_t tclass, access_vector_t perms, 180 security_class_t tclass, access_vector_t perms,
|
/third_party/selinux/libsepol/src/ |
D | assertion.c | 49 const class_perm_node_t *curperm, uint32_t perms) in report_failure() argument 57 sepol_av_to_string(p, curperm->tclass, perms)); in report_failure() 63 sepol_av_to_string(p, curperm->tclass, perms)); in report_failure() 69 sepol_av_to_string(p, curperm->tclass, perms)); in report_failure() 99 rc = extended_permissions_and(neverallow->perms, allow->perms); in check_extended_permissions() 102 rc = xperm_test(neverallow->driver, allow->perms); in check_extended_permissions() 105 rc = xperm_test(allow->driver, neverallow->perms); in check_extended_permissions() 108 rc = extended_permissions_and(neverallow->perms, allow->perms); in check_extended_permissions() 125 result->perms[i] = neverallow->perms[i] & allow->perms[i]; in extended_permissions_violated() 130 memcpy(result->perms, neverallow->perms, sizeof(result->perms)); in extended_permissions_violated() [all …]
|
D | util.c | 150 for (bit = 0; bit < sizeof(xperms->perms)*8; bit++) { in sepol_extended_perms_to_string() 151 if (!xperm_test(bit, xperms->perms)) in sepol_extended_perms_to_string() 154 if (in_range && next_bit_in_range(bit, xperms->perms)) { in sepol_extended_perms_to_string() 157 } else if (next_bit_in_range(bit, xperms->perms)) { in sepol_extended_perms_to_string()
|
D | kernel_to_cil.c | 284 char *perms; in class_constraint_rules_to_strs() local 298 perms = sepol_av_to_string(pdb, class->s.value, curr->permissions); in class_constraint_rules_to_strs() 308 rc = strs_create_and_add(strs, "(%s (%s (%s)) %s)", 4, key_word, classkey, perms+1, expr); in class_constraint_rules_to_strs() 438 char *perms = NULL; in class_or_common_perms_to_str() local 452 perms = strs_to_str(strs); in class_or_common_perms_to_str() 458 return perms; in class_or_common_perms_to_str() 466 char *name, *perms; in write_class_decl_rules_to_cil() local 475 perms = class_or_common_perms_to_str(&class->permissions); in write_class_decl_rules_to_cil() 476 if (perms) { in write_class_decl_rules_to_cil() 477 sepol_printf(out, "(class %s (%s))\n", name, perms); in write_class_decl_rules_to_cil() [all …]
|
D | module_to_cil.c | 568 char *perms; in avrule_to_cil() local 603 perms = sepol_av_to_string(pdb, classperm->tclass, classperm->data); in avrule_to_cil() 604 if (perms == NULL) { in avrule_to_cil() 612 perms + 1); in avrule_to_cil() 642 for (bit = 0; bit < sizeof(xperms->perms)*8; bit++) { in xperms_to_cil() 643 if (!xperm_test(bit, xperms->perms)) in xperms_to_cil() 646 if (in_range && next_bit_in_range(bit, xperms->perms)) { in xperms_to_cil() 649 } else if (next_bit_in_range(bit, xperms->perms)) { in xperms_to_cil() 1213 …rc = avrulex_to_cil(indent, pdb, avrule->specified, snames[s], tnames[t], avrule->perms, avrule->x… in avrule_list_to_cil() 1215 rc = avrule_to_cil(indent, pdb, avrule->specified, snames[s], tnames[t], avrule->perms); in avrule_list_to_cil() [all …]
|
D | kernel_to_conf.c | 279 char *perms, *expr; in class_constraint_rules_to_strs() local 293 perms = sepol_av_to_string(pdb, class->s.value, curr->permissions); in class_constraint_rules_to_strs() 294 if (strchr(perms, ' ')) { in class_constraint_rules_to_strs() 311 perm_prefix, perms+1, perm_suffix, in class_constraint_rules_to_strs() 524 char *perms = NULL; in class_or_common_perms_to_str() local 538 perms = strs_to_str(strs); in class_or_common_perms_to_str() 544 return perms; in class_or_common_perms_to_str() 552 char *name, *perms; in write_class_and_common_rules_to_conf() local 576 perms = class_or_common_perms_to_str(&common->permissions); in write_class_and_common_rules_to_conf() 577 if (!perms) { in write_class_and_common_rules_to_conf() [all …]
|
D | optimize.c | 182 return process_xperms(x1->perms, x2->perms); in process_avtab_datum() 185 return xperm_test(x1->driver, x2->perms); in process_avtab_datum() 191 return process_xperms(x1->perms, x2->perms); in process_avtab_datum()
|
/third_party/ntfs-3g/libntfs-3g/ |
D | acls.c | 969 int perms; in ntfs_valid_posix() local 1009 perms = pacl->ace[i].perms; in ntfs_valid_posix() 1013 if (perms & ~7) ok = FALSE; in ntfs_valid_posix() 1026 pchk->mode |= perms << 6; in ntfs_valid_posix() 1033 pchk->mode = (pchk->mode & 07707) | (perms << 3); in ntfs_valid_posix() 1040 pchk->mode |= perms; in ntfs_valid_posix() 1050 pchk->mode = (pchk->mode & 07707) | (perms << 3); in ntfs_valid_posix() 1098 mode |= (pace->perms & 7) << 6; in posix_header() 1102 mode = (mode & 07707) | ((pace->perms & 7) << 3); in posix_header() 1105 mode |= pace->perms & 7; in posix_header() [all …]
|
D | security.c | 1356 int perms; in ntfs_basic_perms() local 1361 perms = pxdesc->mode; in ntfs_basic_perms() 1365 perms = (perms & 07707) in ntfs_basic_perms() 1366 | ((pace->perms & 7) << 3); in ntfs_basic_perms() 1374 perms |= pace->perms & 7; in ntfs_basic_perms() 1377 return (perms); in ntfs_basic_perms() 1939 mode_t perms; in access_check_posix() local 1944 perms = ntfs_basic_perms(scx, pxdesc); in access_check_posix() 1946 perms = pxdesc->mode; in access_check_posix() 1951 if (perms & 0101) in access_check_posix() [all …]
|
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-subzero/include/llvm/Support/ |
D | FileSystem.h | 75 enum perms { enum 100 inline perms operator|(perms l, perms r) { 101 return static_cast<perms>(static_cast<unsigned short>(l) | 104 inline perms operator&(perms l, perms r) { 105 return static_cast<perms>(static_cast<unsigned short>(l) & 108 inline perms &operator|=(perms &l, perms r) { 112 inline perms &operator&=(perms &l, perms r) { 116 inline perms operator~(perms x) { 117 return static_cast<perms>(~static_cast<unsigned short>(x)); 165 perms Perms; [all …]
|
/third_party/skia/third_party/externals/swiftshader/third_party/llvm-10.0/llvm/include/llvm/Support/ |
D | FileSystem.h | 86 enum perms { enum 112 inline perms operator|(perms l, perms r) { 113 return static_cast<perms>(static_cast<unsigned short>(l) | 116 inline perms operator&(perms l, perms r) { 117 return static_cast<perms>(static_cast<unsigned short>(l) & 120 inline perms &operator|=(perms &l, perms r) { 124 inline perms &operator&=(perms &l, perms r) { 128 inline perms operator~(perms x) { 130 return static_cast<perms>( 176 perms Perms = perms_not_known; [all …]
|
/third_party/ltp/testcases/cve/ |
D | cve-2016-10044.c | 33 char perms[8], line[BUFSIZ]; in run() local 47 if (sscanf(line, "%*x-%*x %s", perms) != 1) in run() 49 if (strchr(perms, (int)'x')) in run() 50 tst_res(TFAIL, "AIO mapping is executable: %s!", perms); in run() 52 tst_res(TPASS, "AIO mapping is not executable: %s", perms); in run()
|
/third_party/selinux/libsepol/cil/src/ |
D | cil_find.c | 154 cil_list_for_each(i1, cp1->perms) { in cil_classperms_match_any() 156 cil_list_for_each(i2, cp2->perms) { in cil_classperms_match_any() 177 cil_list_for_each(i, cp->perms) { in __cil_classperms_list_match_any() 206 cil_list_for_each(i, cp->perms) { in cil_classperms_list_match_any() 233 cil_list_for_each(i, cp->perms) { in __add_classes_from_classperms_list() 265 cil_symtab_map(&class->perms, __add_classes_from_map_perms, class_list); in cil_expand_class() 279 if (!ebitmap_match_any(px1->perms, px2->perms)) goto exit; in cil_permissionx_match_any() 336 if (cil_classperms_list_match_any(avrule->perms.classperms, target->perms.classperms)) { in cil_find_matching_avrule() 340 if (cil_permissionx_match_any(avrule->perms.x.permx, target->perms.x.permx)) { in cil_find_matching_avrule()
|
D | cil_post.c | 1022 permx->perms = cil_malloc(sizeof(*permx->perms)); in __evaluate_permissionx_expression() 1023 ebitmap_init(permx->perms); in __evaluate_permissionx_expression() 1025 …rc = __cil_expr_to_bitmap(permx->expr_str, permx->perms, 0x10000, db); // max is one more than 0xF… in __evaluate_permissionx_expression() 1028 ebitmap_destroy(permx->perms); in __evaluate_permissionx_expression() 1029 free(permx->perms); in __evaluate_permissionx_expression() 1030 permx->perms = NULL; in __evaluate_permissionx_expression() 1570 if (rule->perms.x.permx_str == NULL) { in __cil_post_db_attr_helper() 1571 rc = __evaluate_permissionx_expression(rule->perms.x.permx, db); in __cil_post_db_attr_helper() 2029 ebitmap_t *perms; member 2036 ebitmap_t *perms = perm_args->perms; in __perm_bits_to_list() local [all …]
|
D | cil_binary.c | 1318 static int __cil_perms_to_datum(struct cil_list *perms, class_datum_t *sepol_class, uint32_t *datum) in __cil_perms_to_datum() argument 1326 cil_list_for_each(curr_perm, perms) { in __cil_perms_to_datum() 1402 rc = __cil_perms_to_datum(cp->perms, sepol_class, &data); in __cil_avrule_expand_helper() 1447 cil_list_for_each(i, cp->perms) { in __cil_avrule_expand() 1493 struct cil_list *classperms = cil_avrule->perms.classperms; in __cil_avrule_to_avtab() 1621 xperms->perms[i] |= ~0U; in __avrule_xperm_setrangebits() 1624 xperms->perms[i] |= XPERM_SETBITS(h); in __avrule_xperm_setrangebits() 1627 xperms->perms[i] |= ~0U - XPERM_SETBITS(low); in __avrule_xperm_setrangebits() 1630 xperms->perms[i] |= XPERM_SETBITS(h) - XPERM_SETBITS(low); in __avrule_xperm_setrangebits() 1833 …rulex_ioctl_table, kind, sepol_src->s.value, sepol_tgt->s.value, sepol_obj->s.value, permx->perms); in __cil_avrulex_to_hashtable_helper() [all …]
|
/third_party/e2fsprogs/ |
D | 1004-modify-code-to-compile.patch | 23 diff --git a/contrib/android/perms.c b/contrib/android/perms.c 25 --- a/contrib/android/perms.c 26 +++ b/contrib/android/perms.c 29 #include "perms.h"
|
D | 1003-add-dac-config.patch | 285 diff --git a/contrib/android/perms.c b/contrib/android/perms.c 287 --- a/contrib/android/perms.c 288 +++ b/contrib/android/perms.c 315 diff --git a/contrib/android/perms.h b/contrib/android/perms.h 317 --- a/contrib/android/perms.h 318 +++ b/contrib/android/perms.h
|
/third_party/skia/infra/bots/ |
D | zip_utils.py | 44 perms = os.stat(filepath).st_mode 51 zi.external_attr = perms << 16 77 perms = zi.external_attr >> 16 78 os.chmod(dst_path, perms)
|
/third_party/ntfs-3g/ntfsprogs/ |
D | ntfssecaudit.c | 1517 int perms; in showposix() local 1543 perms = pxace->perms; in showposix() 1545 txperm[0] = (perms & S_ISVTX ? 's' : '-'); in showposix() 1546 txperm[1] = (perms & S_ISUID ? 'u' : '-'); in showposix() 1547 txperm[2] = (perms & S_ISGID ? 'g' : '-'); in showposix() 1549 txperm[0] = (perms & 4 ? 'r' : '-'); in showposix() 1550 txperm[1] = (perms & 2 ? 'w' : '-'); in showposix() 1551 txperm[2] = (perms & 1 ? 'x' : '-'); in showposix() 1587 perms,txperm); in showposix() 2492 rights |= (pxace[i].perms & 7) << 6; in merge_rights() [all …]
|
/third_party/musl/libc-test/src/functionalext/supplement/linux/ |
D | lgetxattr.c | 36 mode_t perms = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH; in lgetxattr_0100() local 37 int fd = open(path, O_RDWR | O_CREAT, perms); in lgetxattr_0100()
|
D | listxattr.c | 36 mode_t perms = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH; in listxattr_0100() local 37 int fd = open(path, O_RDWR | O_CREAT, perms); in listxattr_0100()
|
D | llistxattr.c | 36 mode_t perms = S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH; in llistxattr_0100() local 37 int fd = open(path, O_RDWR | O_CREAT, perms); in llistxattr_0100()
|