Home
last modified time | relevance | path

Searched refs:uid (Results 1 – 22 of 22) sorted by relevance

/kernel/
Duser.c83 #define __uidhashfn(uid) (((uid >> UIDHASH_BITS) + uid) & UIDHASH_MASK) argument
84 #define uidhashentry(uid) (uidhash_table + __uidhashfn((__kuid_val(uid)))) argument
103 .uid = GLOBAL_ROOT_UID,
120 static struct user_struct *uid_hash_find(kuid_t uid, struct hlist_head *hashent) in uid_hash_find() argument
125 if (uid_eq(user->uid, uid)) { in uid_hash_find()
170 struct user_struct *find_user(kuid_t uid) in find_user() argument
176 ret = uid_hash_find(uid, uidhashentry(uid)); in find_user()
194 struct user_struct *alloc_uid(kuid_t uid) in alloc_uid() argument
196 struct hlist_head *hashent = uidhashentry(uid); in alloc_uid()
200 up = uid_hash_find(uid, hashent); in alloc_uid()
[all …]
Ducount.c13 .uid = GLOBAL_ROOT_UID,
21 #define ucounts_hashfn(ns, uid) \ argument
22 hash_long((unsigned long)__kuid_val(uid) + (unsigned long)(ns), \
24 #define ucounts_hashentry(ns, uid) \ argument
25 (ucounts_hashtable + ucounts_hashfn(ns, uid))
130 static struct ucounts *find_ucounts(struct user_namespace *ns, kuid_t uid, struct hlist_head *hashe… in find_ucounts() argument
135 if (uid_eq(ucounts->uid, uid) && (ucounts->ns == ns)) in find_ucounts()
143 struct hlist_head *hashent = ucounts_hashentry(ucounts->ns, ucounts->uid); in hlist_add_ucounts()
164 struct ucounts *alloc_ucounts(struct user_namespace *ns, kuid_t uid) in alloc_ucounts() argument
166 struct hlist_head *hashent = ucounts_hashentry(ns, uid); in alloc_ucounts()
[all …]
Dsys.c177 if (uid_eq(pcred->uid, cred->euid) || in set_one_prio_perm()
220 kuid_t uid; in SYSCALL_DEFINE3() local
254 uid = make_kuid(cred->user_ns, who); in SYSCALL_DEFINE3()
257 uid = cred->uid; in SYSCALL_DEFINE3()
258 else if (!uid_eq(uid, cred->uid)) { in SYSCALL_DEFINE3()
259 user = find_user(uid); in SYSCALL_DEFINE3()
264 if (uid_eq(task_uid(p), uid) && task_pid_vnr(p)) in SYSCALL_DEFINE3()
267 if (!uid_eq(uid, cred->uid)) in SYSCALL_DEFINE3()
290 kuid_t uid; in SYSCALL_DEFINE2() local
322 uid = make_kuid(cred->user_ns, who); in SYSCALL_DEFINE2()
[all …]
Duid16.c53 SYSCALL_DEFINE1(setuid16, old_uid_t, uid) in SYSCALL_DEFINE1() argument
55 return __sys_setuid(low2highuid(uid)); in SYSCALL_DEFINE1()
70 ruid = high2lowuid(from_kuid_munged(cred->user_ns, cred->uid)); in SYSCALL_DEFINE3()
104 SYSCALL_DEFINE1(setfsuid16, old_uid_t, uid) in SYSCALL_DEFINE1() argument
106 return __sys_setfsuid(low2highuid(uid)); in SYSCALL_DEFINE1()
Dauditsc.c329 static int audit_compare_uid(kuid_t uid, in audit_compare_uid() argument
338 rc = audit_uid_comparator(uid, f->op, name->uid); in audit_compare_uid()
345 rc = audit_uid_comparator(uid, f->op, n->uid); in audit_compare_uid()
386 return audit_compare_uid(cred->uid, name, f, ctx); in audit_field_compare()
405 return audit_uid_comparator(cred->uid, f->op, in audit_field_compare()
408 return audit_uid_comparator(cred->uid, f->op, cred->euid); in audit_field_compare()
410 return audit_uid_comparator(cred->uid, f->op, cred->suid); in audit_field_compare()
412 return audit_uid_comparator(cred->uid, f->op, cred->fsuid); in audit_field_compare()
502 result = audit_uid_comparator(cred->uid, f->op, f->uid); in audit_filter_rules()
505 result = audit_uid_comparator(cred->euid, f->op, f->uid); in audit_filter_rules()
[all …]
Duid16.h5 long __sys_setuid(uid_t uid);
11 long __sys_setfsuid(uid_t uid);
Dexit.c1043 uid_t uid; member
1104 uid_t uid = from_kuid_munged(current_user_ns(), task_uid(p)); in wait_task_zombie() local
1224 infop->uid = uid; in wait_task_zombie()
1265 uid_t uid = 0; /* unneeded, required by compiler */ in wait_task_stopped() local
1291 uid = from_kuid_munged(current_user_ns(), task_uid(p)); in wait_task_stopped()
1321 infop->uid = uid; in wait_task_stopped()
1336 uid_t uid; in wait_task_continued() local
1352 uid = from_kuid_munged(current_user_ns(), task_uid(p)); in wait_task_continued()
1369 infop->uid = uid; in wait_task_continued()
1737 unsafe_put_user(info.uid, &infop->si_uid, Efault); in SYSCALL_DEFINE5()
[all …]
Duser_namespace.c33 static struct ucounts *inc_user_namespaces(struct user_namespace *ns, kuid_t uid) in inc_user_namespaces() argument
35 return inc_ucount(ns, uid, UCOUNT_USER_NAMESPACES); in inc_user_namespaces()
408 kuid_t make_kuid(struct user_namespace *ns, uid_t uid) in make_kuid() argument
411 return KUIDT_INIT(map_id_down(&ns->uid_map, uid)); in make_kuid()
454 uid_t uid; in from_kuid_munged() local
455 uid = from_kuid(targ, kuid); in from_kuid_munged()
457 if (uid == (uid_t) -1) in from_kuid_munged()
458 uid = overflowuid; in from_kuid_munged()
459 return uid; in from_kuid_munged()
1176 kuid_t uid = make_kuid(ns->parent, id); in new_idmap_permitted() local
[all …]
Dcred.c49 .uid = GLOBAL_ROOT_UID,
511 if (!uid_eq(new->uid, old->uid) || in commit_creds()
680 if (old_ucounts->ns == new->user_ns && uid_eq(old_ucounts->uid, new->uid)) in set_cred_ucounts()
683 if (!(new_ucounts = alloc_ucounts(new->user_ns, new->uid))) in set_cred_ucounts()
856 from_kuid_munged(&init_user_ns, cred->uid), in dump_invalid_creds()
Daudit.h81 kuid_t uid; member
137 kuid_t uid, euid, suid, fsuid; member
160 kuid_t uid; member
Daudit.c1090 uid_t uid = from_kuid(&init_user_ns, current_uid()); in audit_log_common_recv_msg() local
1101 audit_log_format(*ab, "pid=%d uid=%u ", pid, uid); in audit_log_common_recv_msg()
1488 sig_data->uid = from_kuid(&init_user_ns, audit_sig_uid); in audit_receive_msg()
1617 from_kuid(&init_user_ns, cred->uid), in audit_log_multicast()
2264 from_kuid(&init_user_ns, cred->uid), in audit_log_task_info()
2330 uid_t uid, oldloginuid, loginuid; in audit_log_set_loginuid() local
2340 uid = from_kuid(&init_user_ns, task_uid(current)); in audit_log_set_loginuid()
2345 audit_log_format(ab, "pid=%d uid=%u", task_tgid_nr(current), uid); in audit_log_set_loginuid()
2399 kuid_t uid = current_uid(), auid; in audit_signal_info() local
2409 audit_sig_uid = uid; in audit_signal_info()
Dauditfilter.c497 f->uid = make_kuid(current_user_ns(), f_val); in audit_data_to_entry()
498 if (!uid_valid(f->uid)) in audit_data_to_entry()
761 if (!uid_eq(a->fields[i].uid, b->fields[i].uid)) in audit_compare_rule()
1349 result = audit_uid_comparator(current_uid(), f->op, f->uid); in audit_filter()
1356 f->op, f->uid); in audit_filter()
Dsignal.c832 uid_eq(cred->euid, tcred->uid) || in kill_ok_by_cred()
833 uid_eq(cred->uid, tcred->suid) || in kill_ok_by_cred()
834 uid_eq(cred->uid, tcred->uid) || in kill_ok_by_cred()
1252 kuid_t uid = make_kuid(current_user_ns(), info->si_uid); in send_signal_locked() local
1253 info->si_uid = from_kuid_munged(t_user_ns, uid); in send_signal_locked()
1528 uid_eq(cred->euid, pcred->uid) || in kill_as_cred_perm()
1529 uid_eq(cred->uid, pcred->suid) || in kill_as_cred_perm()
1530 uid_eq(cred->uid, pcred->uid); in kill_as_cred_perm()
Dtsacct.c62 stats->ac_uid = from_kuid_munged(user_ns, tcred->uid); in bacct_add_tsk()
Dptrace.c323 caller_uid = cred->uid; in __ptrace_may_access()
329 uid_eq(caller_uid, tcred->uid) && in __ptrace_may_access()
Dacct.c516 ac.ac_uid = from_kuid_munged(file->f_cred->user_ns, orig_cred->uid); in do_acct_process()
/kernel/bpf/
Dhelpers.c236 kuid_t uid; in BPF_CALL_0() local
242 current_uid_gid(&uid, &gid); in BPF_CALL_0()
244 from_kuid(&init_user_ns, uid); in BPF_CALL_0()
Dsyscall.c3940 prog->aux->user->uid); in bpf_prog_get_info_by_fd()
/kernel/cgroup/
Dcgroup-v1.c516 !uid_eq(cred->euid, tcred->uid) && in __cgroup1_procs_write()
/kernel/trace/
Dtrace.h177 kuid_t uid; member
Dtrace.c1798 max_data->uid = current_uid(); in __update_max_tr()
1800 max_data->uid = task_uid(tsk); in __update_max_tr()
4335 from_kuid_munged(seq_user_ns(m), data->uid), data->nice, in print_trace_header()
/kernel/sched/
Dcore.c7587 uid_eq(cred->euid, pcred->uid)); in check_same_owner()