Lines Matching refs:creds
46 static __inline__ int scm_check_creds(struct ucred *creds) in scm_check_creds() argument
49 kuid_t uid = make_kuid(cred->user_ns, creds->uid); in scm_check_creds()
50 kgid_t gid = make_kgid(cred->user_ns, creds->gid); in scm_check_creds()
55 if ((creds->pid == task_tgid_vnr(current) || in scm_check_creds()
170 struct ucred creds; in __scm_send() local
175 memcpy(&creds, CMSG_DATA(cmsg), sizeof(struct ucred)); in __scm_send()
176 err = scm_check_creds(&creds); in __scm_send()
180 p->creds.pid = creds.pid; in __scm_send()
181 if (!p->pid || pid_vnr(p->pid) != creds.pid) { in __scm_send()
184 pid = find_get_pid(creds.pid); in __scm_send()
192 uid = make_kuid(current_user_ns(), creds.uid); in __scm_send()
193 gid = make_kgid(current_user_ns(), creds.gid); in __scm_send()
197 p->creds.uid = uid; in __scm_send()
198 p->creds.gid = gid; in __scm_send()