/third_party/ltp/testcases/kernel/syscalls/setreuid/ |
D | setreuid04.c | 54 &nobody.pw_uid, &nobody.pw_uid, &nobody, &nobody, 121 UID16_CHECK(root.pw_uid, setreuid, cleanup); in setup() 124 UID16_CHECK(nobody.pw_uid, setreuid, cleanup); in setup() 135 if ((getuid() != ru->pw_uid) || (geteuid() != eu->pw_uid)) { in uid_verify() 139 ru->pw_uid, eu->pw_uid); in uid_verify()
|
/third_party/ltp/testcases/kernel/syscalls/setresuid/ |
D | setresuid05.c | 71 UID16_CHECK(ltpuser->pw_uid, "setresuid", cleanup) in setup() 78 TEST(SETRESUID(cleanup, -1, ltpuser->pw_uid, -1)); in setresuid_verify() 89 if (ltpuser->pw_uid == buf.st_uid) { in setresuid_verify() 94 ltpuser->pw_uid, buf.st_uid); in setresuid_verify()
|
/third_party/pulseaudio/src/tests/ |
D | usergroup-test.c | 92 if (a->pw_uid != b->pw_uid) { in compare_passwd() 93 …tf(stderr, "pw_uid mismatch: [%lu] [%lu]\n", (unsigned long) a->pw_uid, (unsigned long) b->pw_uid); in compare_passwd() 139 pw = pa_getpwuid_malloc(reference_passwd->pw_uid); in START_TEST()
|
/third_party/python/Lib/test/ |
D | test_pwd.py | 19 self.assertEqual(e[2], e.pw_uid) 20 self.assertIsInstance(e.pw_uid, int) 46 entriesbyuid.setdefault(e.pw_uid, []).append(e) 54 self.assertIn(pwd.getpwuid(e.pw_uid), entriesbyuid[e.pw_uid])
|
/third_party/ltp/testcases/kernel/syscalls/mlockall/ |
D | mlockall02.c | 196 if (seteuid(ltpuser->pw_uid) == -1) { in setup_test() 200 ltpuser->pw_uid, TEST_ERRNO, in setup_test() 219 if (seteuid(ltpuser->pw_uid) == -1) { in setup_test() 222 ltpuser->pw_uid, TEST_ERRNO, in setup_test()
|
D | mlockall03.c | 222 if (seteuid(ltpuser->pw_uid) == -1) { in setup_test() 225 ltpuser->pw_uid, TEST_ERRNO, in setup_test() 252 if (seteuid(ltpuser->pw_uid) == -1) { in setup_test() 255 ltpuser->pw_uid, TEST_ERRNO, in setup_test()
|
/third_party/ltp/testcases/kernel/syscalls/geteuid/ |
D | geteuid02.c | 56 UID16_CHECK(pwent->pw_uid, geteuid, cleanup); in main() 57 if (pwent->pw_uid != TEST_RETURN) in main() 60 "value, %ld", pwent->pw_uid, in main()
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/shm_unlink/ |
D | 9-1.c | 49 if (strcmp(pw->pw_name, "root") && pw->pw_uid != getuid()) in main() 57 if (seteuid(pw->pw_uid) != 0) { in main() 67 printf("Testing with user '%s' (uid: %i)\n", pw->pw_name, pw->pw_uid); in main()
|
D | 8-1.c | 63 if (strcmp(pw->pw_name, "root") && pw->pw_uid != getuid()) in main() 71 if (seteuid(pw->pw_uid) != 0) { in main() 81 printf("Testing with user '%s' (uid: %i)\n", pw->pw_name, pw->pw_uid); in main()
|
/third_party/toybox/toys/posix/ |
D | id.c | 98 uid = euid = pw->pw_uid; in do_id() 105 if (toys.optflags&FLAG_u) s_or_u(pw->pw_name, pw->pw_uid, 1); in do_id() 111 showid("uid=", pw->pw_uid, pw->pw_name); in do_id() 117 showid(" euid=", pw->pw_uid, pw->pw_name); in do_id()
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/shm_open/ |
D | 26-2.c | 73 if (strcmp(pw->pw_name, "root") && pw->pw_uid != getuid()) in main() 82 if (seteuid(pw->pw_uid) != 0) { in main() 93 printf("Testing with user '%s' (uid: %i)\n", pw->pw_name, pw->pw_uid); in main()
|
/third_party/ltp/testcases/kernel/syscalls/creat/ |
D | creat09.c | 55 tst_res(TINFO, "User nobody: uid = %d, gid = %d", (int)ltpuser->pw_uid, in setup() 61 SAFE_CHOWN(WORKDIR, ltpuser->pw_uid, free_gid); in setup() 75 SAFE_SETREUID(-1, ltpuser->pw_uid); in setup()
|
/third_party/ltp/testcases/open_posix_testsuite/conformance/interfaces/sched_getparam/ |
D | 6-1.c | 38 if (pw->pw_uid != 0) in set_nonroot() 55 if (setuid(pw->pw_uid) != 0) { in set_nonroot()
|
/third_party/musl/libc-test/src/functionalext/supplement/passwd/ |
D | getpwent.c | 44 EXPECT_EQ("getpwnam_0100", ret->pw_uid, CMPFLAG); in getpwnam_0100() 70 EXPECT_EQ("getpwuid_0100", ret->pw_uid, getuid()); in getpwuid_0100()
|
/third_party/musl/src/passwd/ |
D | getpw_a.c | 38 || !name && (*res)->pw_uid == uid) in __getpw_a() 112 pw->pw_uid = passwdbuf[PWUID]; in __getpw_a() 126 || !name && uid != pw->pw_uid) { in __getpw_a()
|
/third_party/ltp/testcases/kernel/syscalls/mkdir/ |
D | mkdir02.c | 64 SAFE_SETREUID(pw->pw_uid, pw->pw_uid); in setup()
|
/third_party/ltp/testcases/kernel/syscalls/setfsuid/ |
D | setfsuid03.c | 95 if (setuid(ltpuser->pw_uid) == -1) in setup() 97 "to set the effective uid to %d", ltpuser->pw_uid); in setup()
|
/third_party/ltp/testcases/kernel/syscalls/setfsgid/ |
D | setfsgid03.c | 95 if (setuid(ltpuser->pw_uid) == -1) in setup() 98 ltpuser->pw_uid); in setup()
|
/third_party/ltp/testcases/kernel/syscalls/lchown/ |
D | lchown02.c | 176 if (setgid(ltpuser->pw_uid) == -1) in setup() 210 if (seteuid(ltpuser->pw_uid) == -1) in setup_eperm() 211 tst_resm(TBROK | TERRNO, "seteuid(%d) failed", ltpuser->pw_uid); in setup_eperm()
|
/third_party/ltp/testcases/kernel/syscalls/fchmod/ |
D | fchmod05.c | 66 SAFE_CHOWN(TESTDIR, ltpuser->pw_uid, free_gid); in setup() 69 SAFE_SETEUID(ltpuser->pw_uid); in setup()
|
D | fchmod04.c | 153 if (seteuid(ltpuser->pw_uid) == -1) { in setup() 155 "to set the effective uid to %d", ltpuser->pw_uid); in setup()
|
/third_party/ltp/testcases/kernel/syscalls/chmod/ |
D | chmod05.c | 87 SAFE_CHOWN(TESTDIR, nobody_u->pw_uid, free_gid); in setup() 91 SAFE_SETEUID(nobody_u->pw_uid); in setup()
|
/third_party/ltp/testcases/kernel/syscalls/getresuid/ |
D | getresuid02.c | 155 pe_uid = user_id->pw_uid; in setup() 158 ps_uid = user_id->pw_uid; in setup()
|
/third_party/pulseaudio/src/daemon/ |
D | main.c | 275 PA_SYSTEM_USER, (unsigned long) pw->pw_uid, in change_user() 286 if (pa_make_secure_dir(PA_SYSTEM_RUNTIME_PATH, 0755, pw->pw_uid, gr->gr_gid, true) < 0) { in change_user() 291 if (pa_make_secure_dir(PA_SYSTEM_STATE_PATH, 0700, pw->pw_uid, gr->gr_gid, true) < 0) { in change_user() 320 r = setresuid(pw->pw_uid, pw->pw_uid, pw->pw_uid); in change_user() 322 if ((r = setuid(pw->pw_uid)) >= 0) in change_user() 323 r = seteuid(pw->pw_uid); in change_user() 325 r = setreuid(pw->pw_uid, pw->pw_uid); in change_user()
|
/third_party/libwebsockets/lib/plat/unix/ |
D | unix-caps.c | 104 *puid = p->pw_uid; 151 context->uid = p->pw_uid; 154 context->username, (unsigned int)p->pw_uid);
|