Home
last modified time | relevance | path

Searched refs:test_uid (Results 1 – 3 of 3) sorted by relevance

/systemd-251/src/test/
Dtest-capability.c23 static uid_t test_uid = -1; variable
108 test_uid = nobody->pw_uid; in setup_tests()
126 assert_se(drop_privileges(test_uid, test_gid, test_flags | (1ULL << CAP_NET_RAW)) >= 0); in test_drop_privileges_keep_net_raw()
127 assert_se(getuid() == test_uid); in test_drop_privileges_keep_net_raw()
143 assert_se(drop_privileges(test_uid, test_gid, test_flags) >= 0); in test_drop_privileges_dontkeep_net_raw()
144 assert_se(getuid() == test_uid); in test_drop_privileges_dontkeep_net_raw()
153 assert_se(drop_privileges(test_uid, test_gid, test_flags) >= 0); in test_drop_privileges_fail()
154 assert_se(getuid() == test_uid); in test_drop_privileges_fail()
157 assert_se(drop_privileges(test_uid, test_gid, test_flags) < 0); in test_drop_privileges_fail()
177 assert_se(drop_privileges(test_uid, test_gid, test_flags | (1ULL << CAP_KILL)) >= 0); in test_have_effective_cap()
[all …]
Dtest-fs-util.c551 uid_t test_uid, test_gid; in TEST() local
558 test_uid = geteuid() == 0 ? 65534 : getuid(); in TEST()
567 r = touch_file(a, false, test_mtime, test_uid, test_gid, 0640); in TEST()
575 assert_se(st.st_uid == test_uid); in TEST()
583 assert_se(touch_file(a, false, test_mtime, test_uid, test_gid, 0640) >= 0); in TEST()
585 assert_se(st.st_uid == test_uid); in TEST()
593 assert_se(touch_file(a, false, test_mtime, test_uid, test_gid, 0640) >= 0); in TEST()
595 assert_se(st.st_uid == test_uid); in TEST()
603 assert_se(touch_file(a, false, test_mtime, test_uid, test_gid, 0640) >= 0); in TEST()
605 assert_se(st.st_uid == test_uid); in TEST()
[all …]
Dtest-socket-util.c168 uid_t test_uid; in TEST() local
174 test_uid = 1; in TEST()
181 assert_se(setresuid(test_uid, test_uid, test_uid) >= 0); in TEST()
186 test_uid = getuid(); in TEST()
203 assert_se(ucred.uid == test_uid); in TEST()