Home
last modified time | relevance | path

Searched refs:capdata (Results 1 – 5 of 5) sorted by relevance

/frameworks/native/cmds/dumpstate/
DDumpstateInternal.cpp98 struct __user_cap_data_struct capdata[2]; in DropRootUser() local
100 memset(&capdata, 0, sizeof(capdata)); in DropRootUser()
104 if (capget(&capheader, &capdata[0]) != 0) { in DropRootUser()
111 bool has_cap_syslog = (capdata[cap_syslog_index].effective & cap_syslog_mask) != 0; in DropRootUser()
113 memset(&capdata, 0, sizeof(capdata)); in DropRootUser()
116 capdata[cap_syslog_index].permitted |= cap_syslog_mask; in DropRootUser()
117 capdata[cap_syslog_index].effective |= cap_syslog_mask; in DropRootUser()
122 capdata[cap_block_suspend_index].permitted |= cap_block_suspend_mask; in DropRootUser()
123 capdata[cap_block_suspend_index].effective |= cap_block_suspend_mask; in DropRootUser()
125 if (capset(&capheader, &capdata[0]) != 0) { in DropRootUser()
[all …]
/frameworks/native/services/vr/performanced/
Dmain.cpp28 struct __user_cap_data_struct capdata[kMaxCapNumber]; in main() local
51 memset(&capdata, 0, sizeof(capdata)); in main()
53 capdata[CAP_TO_INDEX(CAP_SYS_NICE)].effective |= CAP_TO_MASK(CAP_SYS_NICE); in main()
54 capdata[CAP_TO_INDEX(CAP_SYS_NICE)].permitted |= CAP_TO_MASK(CAP_SYS_NICE); in main()
57 ret = capset(&capheader, capdata); in main()
/frameworks/native/cmds/installd/tests/
Dtest_utils.h145 struct __user_cap_data_struct capdata[2]; in DropCapabilities() local
147 memset(&capdata, 0, sizeof(capdata)); in DropCapabilities()
149 if (capset(&capheader, &capdata[0]) < 0) { in DropCapabilities()
/frameworks/base/core/jni/
Dcom_android_internal_os_Zygote.cpp677 __user_cap_data_struct capdata[2]; in SetInheritable() local
678 if (capget(&capheader, &capdata[0]) == -1) { in SetInheritable()
682 capdata[0].inheritable = inheritable; in SetInheritable()
683 capdata[1].inheritable = inheritable >> 32; in SetInheritable()
685 if (capset(&capheader, &capdata[0]) == -1) { in SetInheritable()
697 __user_cap_data_struct capdata[2]; in SetCapabilities() local
698 memset(&capdata, 0, sizeof(capdata)); in SetCapabilities()
699 capdata[0].effective = effective; in SetCapabilities()
700 capdata[1].effective = effective >> 32; in SetCapabilities()
701 capdata[0].permitted = permitted; in SetCapabilities()
[all …]
/frameworks/native/cmds/installd/
Dutils.cpp1189 struct __user_cap_data_struct capdata[2]; in drop_capabilities() local
1191 memset(&capdata, 0, sizeof(capdata)); in drop_capabilities()
1193 if (capset(&capheader, &capdata[0]) < 0) { in drop_capabilities()