Home
last modified time | relevance | path

Searched refs:getuid (Results 1 - 25 of 232) sorted by relevance

12345678910

/third_party/rust/crates/rustix/tests/process/
H A Did.rs5 assert_eq!(process::getuid(), process::getuid()); in test_getuid()
7 assert_eq!(process::getuid().as_raw(), libc::getuid()); in test_getuid()
8 assert_eq!(process::getuid().is_root(), libc::getuid() == 0); in test_getuid()
/third_party/musl/libc-test/src/functionalext/supplement/misc/misc_gtest/
H A Dmisc_getpriority_test.cpp11 priorityNum = getpriority(PRIO_USER, getuid());
20 setpriority(PRIO_USER, getuid(), priorityNum);
66 int result1 = setpriority(PRIO_USER, getuid(), PRIORITY); in HWTEST_F()
68 int result2 = getpriority(PRIO_USER, getuid()); in HWTEST_F()
/third_party/musl/libc-test/src/functionalext/supplement/unistd/
H A Dsetreuid.c27 uid_t cuid = getuid(); in setreuid_0100()
37 uid_t uid = getuid(); in setreuid_0100()
57 uid_t cuid = getuid(); in setreuid_0200()
67 uid_t uid = getuid(); in setreuid_0200()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/shm_open/
H A D26-2.c73 if (strcmp(pw->pw_name, "root") && pw->pw_uid != getuid()) in main()
98 if (seteuid(getuid())) in main()
106 if (seteuid(getuid())) in main()
112 if (seteuid(getuid())) in main()
/third_party/musl/libc-test/src/functionalext/supplement/passwd/
H A Dgetpw_r.c32 int ret = getpwuid_r(getuid(), &pw, buf, sizeof(buf), &res); in getpwuid_r_0100()
35 EXPECT_EQ("getpwuid_r_0100", pw.pw_uid, getuid()); in getpwuid_r_0100()
50 int ret = getpwuid_r(getuid(), &pw, buf, 1, &res); in getpwuid_r_0200()
H A Dgetpwent.c67 struct passwd *ret = getpwuid(getuid()); in getpwuid_0100()
70 EXPECT_EQ("getpwuid_0100", ret->pw_uid, getuid()); in getpwuid_0100()
/third_party/ltp/testcases/kernel/syscalls/ipc/semctl/
H A Dsemctl07.c47 if (arg.buf->sem_perm.uid != getuid()) { in verify_semctl()
49 arg.buf->sem_perm.uid, getuid()); in verify_semctl()
61 if (arg.buf->sem_perm.cuid != getuid()) { in verify_semctl()
63 arg.buf->sem_perm.cuid, getuid()); in verify_semctl()
/third_party/musl/libc-test/src/functionalext/supplement/stat/
H A Dfstatat.c41 uid_t uid = getuid(); in fstatat_0100()
68 uid_t uid = getuid(); in fstatat_0200()
97 uid_t uid = getuid(); in fstatat_0300()
120 uid_t uid = getuid(); in fstatat_time64_0100()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/shm_unlink/
H A D9-1.c49 if (strcmp(pw->pw_name, "root") && pw->pw_uid != getuid()) in main()
72 if (seteuid(getuid())) in main()
78 if (seteuid(getuid())) in main()
H A D8-1.c63 if (strcmp(pw->pw_name, "root") && pw->pw_uid != getuid()) in main()
89 if (seteuid(getuid())) in main()
/third_party/ntfs-3g/libfuse-lite/
H A Dfusermount.c79 struct passwd *pw = getpwuid(getuid()); in get_user_name()
106 uid_t new_uid = getuid(); in drop_privs()
248 if (!mount_flags[i].safe && getuid() != 0) { in find_mount_flag()
299 if (getuid() != 0) { in get_mnt_opts()
409 fd, rootmode, getuid(), getgid()); in do_mount()
432 sprintf(d, "fd=%i,rootmode=%o,user_id=%i", fd, rootmode, getuid()); in do_mount()
483 if (getuid() == 0) in check_perm()
507 if ((stbuf->st_mode & S_ISVTX) && stbuf->st_uid != getuid()) { in check_perm()
610 if (getuid() != 0 && mount_max != -1) { in mount_fuse()
/third_party/musl/libc-test/src/functionalext/supplement/misc/
H A Dgetpriority.c43 ret = getpriority(PRIO_USER, getuid()); in getpriority_0100()
80 ret = setpriority(PRIO_USER, getuid(), i); in getpriority_0200()
84 ret = getpriority(PRIO_USER, getuid()); in getpriority_0200()
/third_party/musl/libc-test/src/functionalext/supplement/process/
H A Dfexecverely.c21 uid_t uid = getuid(); in main()
22 EXPECT_EQ("fexecverely", uid, getuid()); in main()
/third_party/libfuse/util/
H A Dfusermount.c103 struct passwd *pw = getpwuid(getuid()); in get_user_name()
117 if (getuid() != 0) { in drop_privs()
118 oldfsuid = setfsuid(getuid()); in drop_privs()
125 if (getuid() != 0) { in restore_privs()
204 uidlen = sprintf(uidstr, "%u", getuid()); in may_unmount()
442 if (getuid() != 0) { in unmount_fuse_locked()
653 if (!mount_flags[i].safe && getuid() != 0) { in find_mount_flag()
705 if (getuid() != 0) { in get_mnt_opts()
810 if (getuid() != 0) { in do_mount()
839 if (getuid() ! in do_mount()
[all...]
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/clock_getcpuclockid/
H A D5-1.c33 if (getuid() == 0) { in main()
50 if (getuid() == 0) { in main()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sigqueue/
H A D3-1.c56 pw->pw_name, (int)getuid(), (int)geteuid()); in set_nonroot()
69 if (getuid() == 0) { in main()
H A D12-1.c53 pw->pw_name, (int)geteuid(), (int)getuid()); in set_nonroot()
66 if (getuid() == 0) { in main()
/third_party/node/deps/npm/node_modules/write-file-atomic/lib/
H A Dindex.js68 const nonroot = !process.getuid || process.getuid() !== 0
103 if (options.chown == null && process.getuid) {
202 if (!options.chown && process.getuid) {
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sched_setscheduler/
H A D20-1.c55 pw->pw_name, (int)geteuid(), (int)getuid()); in set_nonroot()
67 if (getuid() == 0) { in main()
/third_party/node/deps/npm/node_modules/isexe/
H A Dmode.js26 options.uid : process.getuid && process.getuid()
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sched_setparam/
H A D23-6.c50 pw->pw_name, (int)geteuid(), (int)getuid()); in set_nonroot()
67 if (getuid() == 0) { in main()
/third_party/ltp/testcases/kernel/syscalls/pidfd_send_signal/
H A Dpidfd_send_signal02.c77 if (getuid() == 0) { in setup()
86 info.si_uid = getuid(); in setup()
/third_party/pulseaudio/src/daemon/
H A Dcaps.c53 uid = getuid(); in pa_drop_root()
69 pa_assert_se(getuid() == uid); in pa_drop_root()
/third_party/selinux/libselinux/utils/
H A Dtogglesebool.c81 struct passwd *pwd = getpwuid(getuid()); in main()
90 argv[i], getuid()); in main()
/third_party/pulseaudio/src/pulse/
H A Dutil.c118 p = getuid() == 0 ? "root" : NULL; in pa_get_user_name()
129 if ((r = pa_getpwuid_malloc(getuid())) == NULL) { in pa_get_user_name()
130 pa_snprintf(s, l, "%lu", (unsigned long) getuid()); in pa_get_user_name()
190 if ((r = pa_getpwuid_malloc(getuid())) == NULL) { in pa_get_home_dir()

Completed in 13 milliseconds

12345678910