Lines Matching refs:uid

33 static struct ucounts *inc_user_namespaces(struct user_namespace *ns, kuid_t uid)
35 return inc_ucount(ns, uid, UCOUNT_USER_NAMESPACES);
399 * make_kuid - Map a user-namespace uid pair into a kuid.
400 * @ns: User namespace that the uid is in
401 * @uid: User identifier
403 * Maps a user-namespace uid pair into a kernel internal kuid,
406 * When there is no mapping defined for the user-namespace uid
411 kuid_t make_kuid(struct user_namespace *ns, uid_t uid)
413 /* Map the uid to a global kernel uid */
414 return KUIDT_INIT(map_id_down(&ns->uid_map, uid));
419 * from_kuid - Create a uid from a kuid user-namespace pair.
420 * @targ: The user namespace we want a uid in.
421 * @kuid: The kernel internal uid to start with.
424 * return the resulting uid.
432 /* Map the uid from a global kernel uid */
438 * from_kuid_munged - Create a uid from a kuid user-namespace pair.
439 * @targ: The user namespace we want a uid in.
440 * @kuid: The kernel internal uid to start with.
443 * return the resulting uid.
448 * returns a valid uid. This makes from_kuid_munged appropriate
450 * system call and failing to provide a valid uid are not an
457 uid_t uid;
458 uid = from_kuid(targ, kuid);
460 if (uid == (uid_t) -1)
461 uid = overflowuid;
462 return uid;
538 * Maps a user-namespace uid pair into a kernel internal kuid,
548 /* Map the uid to a global kernel uid */
567 /* Map the uid from a global kernel uid */
870 * verify_root_map() - check the uid 0 mapping
875 * If a process requests mapping parent uid 0 into the new ns, verify that the
1179 kuid_t uid = make_kuid(ns->parent, id);
1180 if (uid_eq(uid, cred->euid))