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))
134 static struct ucounts *find_ucounts(struct user_namespace *ns, kuid_t uid, struct hlist_head *hashe… in find_ucounts() argument
139 if (uid_eq(ucounts->uid, uid) && (ucounts->ns == ns)) in find_ucounts()
147 struct hlist_head *hashent = ucounts_hashentry(ucounts->ns, ucounts->uid); in hlist_add_ucounts()
162 struct ucounts *alloc_ucounts(struct user_namespace *ns, kuid_t uid) in alloc_ucounts() argument
164 struct hlist_head *hashent = ucounts_hashentry(ns, uid); in alloc_ucounts()
[all …]
Dsys.c176 if (uid_eq(pcred->uid, cred->euid) || in set_one_prio_perm()
219 kuid_t uid; in SYSCALL_DEFINE3() local
252 uid = make_kuid(cred->user_ns, who); in SYSCALL_DEFINE3()
255 uid = cred->uid; in SYSCALL_DEFINE3()
256 else if (!uid_eq(uid, cred->uid)) { in SYSCALL_DEFINE3()
257 user = find_user(uid); in SYSCALL_DEFINE3()
262 if (uid_eq(task_uid(p), uid) && task_pid_vnr(p)) in SYSCALL_DEFINE3()
265 if (!uid_eq(uid, cred->uid)) in SYSCALL_DEFINE3()
289 kuid_t uid; in SYSCALL_DEFINE2() local
320 uid = make_kuid(cred->user_ns, who); in SYSCALL_DEFINE2()
[all …]
Dauditsc.c339 static int audit_compare_uid(kuid_t uid, in audit_compare_uid() argument
348 rc = audit_uid_comparator(uid, f->op, name->uid); in audit_compare_uid()
355 rc = audit_uid_comparator(uid, f->op, n->uid); in audit_compare_uid()
396 return audit_compare_uid(cred->uid, name, f, ctx); in audit_field_compare()
415 return audit_uid_comparator(cred->uid, f->op, in audit_field_compare()
418 return audit_uid_comparator(cred->uid, f->op, cred->euid); in audit_field_compare()
420 return audit_uid_comparator(cred->uid, f->op, cred->suid); in audit_field_compare()
422 return audit_uid_comparator(cred->uid, f->op, cred->fsuid); in audit_field_compare()
509 result = audit_uid_comparator(cred->uid, f->op, f->uid); in audit_filter_rules()
512 result = audit_uid_comparator(cred->euid, f->op, f->uid); in audit_filter_rules()
[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()
Duid16.h5 long __sys_setuid(uid_t uid);
11 long __sys_setfsuid(uid_t uid);
Dexit.c1015 uid_t uid; member
1076 uid_t uid = from_kuid_munged(current_user_ns(), task_uid(p)); in wait_task_zombie() local
1195 infop->uid = uid; in wait_task_zombie()
1236 uid_t uid = 0; /* unneeded, required by compiler */ in wait_task_stopped() local
1262 uid = from_kuid_munged(current_user_ns(), task_uid(p)); in wait_task_stopped()
1292 infop->uid = uid; in wait_task_stopped()
1307 uid_t uid; in wait_task_continued() local
1323 uid = from_kuid_munged(current_user_ns(), task_uid(p)); in wait_task_continued()
1340 infop->uid = uid; in wait_task_continued()
1708 unsafe_put_user(info.uid, &infop->si_uid, Efault); in SYSCALL_DEFINE5()
[all …]
Duser_namespace.c32 static struct ucounts *inc_user_namespaces(struct user_namespace *ns, kuid_t uid) in inc_user_namespaces() argument
34 return inc_ucount(ns, uid, UCOUNT_USER_NAMESPACES); in inc_user_namespaces()
403 kuid_t make_kuid(struct user_namespace *ns, uid_t uid) in make_kuid() argument
406 return KUIDT_INIT(map_id_down(&ns->uid_map, uid)); in make_kuid()
449 uid_t uid; in from_kuid_munged() local
450 uid = from_kuid(targ, kuid); in from_kuid_munged()
452 if (uid == (uid_t) -1) in from_kuid_munged()
453 uid = overflowuid; in from_kuid_munged()
454 return uid; in from_kuid_munged()
1171 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.h80 kuid_t uid; member
131 kuid_t uid, euid, suid, fsuid; member
154 kuid_t uid; member
Daudit.c1092 uid_t uid = from_kuid(&init_user_ns, current_uid()); in audit_log_common_recv_msg() local
1103 audit_log_format(*ab, "pid=%d uid=%u ", pid, uid); in audit_log_common_recv_msg()
1490 sig_data->uid = from_kuid(&init_user_ns, audit_sig_uid); in audit_receive_msg()
1619 from_kuid(&init_user_ns, cred->uid), in audit_log_multicast()
2266 from_kuid(&init_user_ns, cred->uid), in audit_log_task_info()
2332 uid_t uid, oldloginuid, loginuid; in audit_log_set_loginuid() local
2342 uid = from_kuid(&init_user_ns, task_uid(current)); in audit_log_set_loginuid()
2347 audit_log_format(ab, "pid=%d uid=%u", task_tgid_nr(current), uid); in audit_log_set_loginuid()
2401 kuid_t uid = current_uid(), auid; in audit_signal_info() local
2411 audit_sig_uid = uid; in audit_signal_info()
Dauditfilter.c489 f->uid = make_kuid(current_user_ns(), f_val); in audit_data_to_entry()
490 if (!uid_valid(f->uid)) in audit_data_to_entry()
753 if (!uid_eq(a->fields[i].uid, b->fields[i].uid)) in audit_compare_rule()
1340 result = audit_uid_comparator(current_uid(), f->op, f->uid); in audit_filter()
1347 f->op, f->uid); in audit_filter()
Dsignal.c820 uid_eq(cred->euid, tcred->uid) || in kill_ok_by_cred()
821 uid_eq(cred->uid, tcred->suid) || in kill_ok_by_cred()
822 uid_eq(cred->uid, tcred->uid) || in kill_ok_by_cred()
1234 kuid_t uid = make_kuid(current_user_ns(), info->si_uid); in send_signal() local
1235 info->si_uid = from_kuid_munged(t_user_ns, uid); in send_signal()
1507 uid_eq(cred->euid, pcred->uid) || in kill_as_cred_perm()
1508 uid_eq(cred->uid, pcred->suid) || in kill_as_cred_perm()
1509 uid_eq(cred->uid, pcred->uid); in kill_as_cred_perm()
Dtsacct.c56 stats->ac_uid = from_kuid_munged(user_ns, tcred->uid); in bacct_add_tsk()
Dptrace.c329 caller_uid = cred->uid; in __ptrace_may_access()
335 uid_eq(caller_uid, tcred->uid) && in __ptrace_may_access()
Dacct.c497 ac.ac_uid = from_kuid_munged(file->f_cred->user_ns, orig_cred->uid); in do_acct_process()
/kernel/bpf/
Dhelpers.c201 kuid_t uid; in BPF_CALL_0() local
207 current_uid_gid(&uid, &gid); in BPF_CALL_0()
209 from_kuid(&init_user_ns, uid); in BPF_CALL_0()
Dsyscall.c3637 prog->aux->user->uid); in bpf_prog_get_info_by_fd()
/kernel/cgroup/
Dcgroup-v1.c521 !uid_eq(cred->euid, tcred->uid) && in __cgroup1_procs_write()
/kernel/trace/
Dtrace.h178 kuid_t uid; member
Dtrace.c1785 max_data->uid = current_uid(); in __update_max_tr()
1787 max_data->uid = task_uid(tsk); in __update_max_tr()
4323 from_kuid_munged(seq_user_ns(m), data->uid), data->nice, in print_trace_header()
/kernel/sched/
Dcore.c7460 uid_eq(cred->euid, pcred->uid)); in check_same_owner()