Home
last modified time | relevance | path

Searched refs:gid_t (Results 1 – 25 of 73) sorted by relevance

123

/linux/kernel/
H A Duid16.h6 long __sys_setgid(gid_t gid);
8 long __sys_setregid(gid_t rgid, gid_t egid);
10 long __sys_setresgid(gid_t rgid, gid_t egid, gid_t sgid);
12 long __sys_setfsgid(gid_t gid);
H A Dgroups.c37 static int groups_to_user(gid_t __user *grouplist, in groups_to_user()
45 gid_t gid; in groups_to_user()
55 gid_t __user *grouplist) in groups_from_user()
62 gid_t gid; in groups_from_user()
161 SYSCALL_DEFINE2(getgroups, int, gidsetsize, gid_t __user *, grouplist) in SYSCALL_DEFINE2()
198 SYSCALL_DEFINE2(setgroups, int, gidsetsize, gid_t __user *, grouplist) in SYSCALL_DEFINE2()
H A Dsys.c383 long __sys_setregid(gid_t rgid, gid_t egid) in __sys_setregid()
394 if ((rgid != (gid_t) -1) && !gid_valid(krgid)) in __sys_setregid()
396 if ((egid != (gid_t) -1) && !gid_valid(kegid)) in __sys_setregid()
405 if (rgid != (gid_t) -1) { in __sys_setregid()
413 if (egid != (gid_t) -1) { in __sys_setregid()
423 if (rgid != (gid_t) -1 || in __sys_setregid()
424 (egid != (gid_t) -1 && !gid_eq(kegid, old->gid))) in __sys_setregid()
439 SYSCALL_DEFINE2(setregid, gid_t, rgid, gid_t, egid) in SYSCALL_DEFINE2() argument
449 long __sys_setgid(gid_t gid) in __sys_setgid()
485 SYSCALL_DEFINE1(setgid, gid_t, gid) in SYSCALL_DEFINE1() argument
[all …]
H A Duser_namespace.c479 kgid_t make_kgid(struct user_namespace *ns, gid_t gid) in make_kgid()
498 gid_t from_kgid(struct user_namespace *targ, kgid_t kgid) in from_kgid()
522 gid_t from_kgid_munged(struct user_namespace *targ, kgid_t kgid) in from_kgid_munged()
524 gid_t gid; in from_kgid_munged()
527 if (gid == (gid_t) -1) in from_kgid_munged()
628 gid_t lower; in gid_m_show()
/linux/include/linux/
H A Duidgid.h31 static inline gid_t __kgid_val(kgid_t gid) in __kgid_val()
41 static inline gid_t __kgid_val(kgid_t gid) in __kgid_val()
110 return __kgid_val(gid) != (gid_t) -1; in gid_valid()
116 extern kgid_t make_kgid(struct user_namespace *from, gid_t gid);
119 extern gid_t from_kgid(struct user_namespace *to, kgid_t gid);
121 extern gid_t from_kgid_munged(struct user_namespace *to, kgid_t gid);
130 return from_kgid(ns, gid) != (gid_t) -1; in kgid_has_mapping()
143 static inline kgid_t make_kgid(struct user_namespace *from, gid_t gid) in make_kgid()
153 static inline gid_t from_kgid(struct user_namespace *to, kgid_t kgid) in from_kgid()
166 static inline gid_t from_kgid_munged(struct user_namespace *to, kgid_t kgid) in from_kgid_munged()
[all …]
H A Dmnt_idmapping.h20 gid_t val;
34 static inline gid_t __vfsgid_val(vfsgid_t gid) in __vfsgid_val()
44 static inline gid_t __vfsgid_val(vfsgid_t gid) in __vfsgid_val()
57 return __vfsgid_val(gid) != (gid_t)-1; in vfsgid_valid()
194 return from_kgid(userns, AS_KGIDT(vfsgid)) != (gid_t)-1; in vfsgid_has_mapping()
H A Dhighuid.h54 #define low2highgid(gid) ((gid) == (old_gid_t)-1 ? (gid_t)-1 : (gid_t)(gid))
H A Dsyscalls.h452 gid_t group, int flag);
453 asmlinkage long sys_fchown(unsigned int fd, uid_t user, gid_t group);
682 asmlinkage long sys_setregid(gid_t rgid, gid_t egid);
683 asmlinkage long sys_setgid(gid_t gid);
688 asmlinkage long sys_setresgid(gid_t rgid, gid_t egid, gid_t sgid);
689 asmlinkage long sys_getresgid(gid_t __user *rgid, gid_t __user *egid, gid_t __user *sgid);
691 asmlinkage long sys_setfsgid(gid_t gid);
697 asmlinkage long sys_getgroups(int gidsetsize, gid_t __user *grouplist);
698 asmlinkage long sys_setgroups(int gidsetsize, gid_t __user *grouplist);
1028 uid_t user, gid_t group);
[all …]
H A Duidgid_types.h12 gid_t val;
H A Dinit_syscalls.h8 int __init init_chown(const char *filename, uid_t user, gid_t group, int flags);
H A Daudit.h405 extern void __audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, umode_t mode);
437 static inline void audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, umode_t mode) in audit_ipc_set_perm()
634 gid_t gid, umode_t mode) in audit_ipc_set_perm()
/linux/tools/testing/selftests/safesetid/
H A Dsafesetid-test.c136 static void ensure_group_exists(gid_t gid) in ensure_group_exists()
322 static void test_setgid(gid_t child_gid, bool expect_success) in test_setgid()
378 static void test_setgroups(gid_t* child_groups, size_t len, bool expect_success) in test_setgroups()
382 gid_t groupset[len]; in test_setgroups()
520 gid_t allowed_supp_groups[2] = {ALLOWED_CHILD1_UGID, ALLOWED_CHILD2_UGID}; in main()
521 gid_t disallowed_supp_groups[2] = {ROOT_UGID, NO_POLICY_UGID}; in main()
/linux/fs/
H A Dmnt_idmapping.c122 gid_t gid; in make_vfsgid()
132 if (gid == (gid_t)-1) in make_vfsgid()
181 gid_t gid; in from_vfsgid()
188 if (gid == (gid_t)-1) in from_vfsgid()
H A Dopen.c747 int chown_common(const struct path *path, uid_t user, gid_t group) in chown_common()
770 if ((group != (gid_t)-1) && !setattr_vfsgid(&newattrs, gid)) in chown_common()
793 int do_fchownat(int dfd, const char __user *filename, uid_t user, gid_t group, in do_fchownat()
826 gid_t, group, int, flag) in SYSCALL_DEFINE5() argument
831 SYSCALL_DEFINE3(chown, const char __user *, filename, uid_t, user, gid_t, group) in SYSCALL_DEFINE3() argument
836 SYSCALL_DEFINE3(lchown, const char __user *, filename, uid_t, user, gid_t, group) in SYSCALL_DEFINE3() argument
842 int vfs_fchown(struct file *file, uid_t user, gid_t group) in vfs_fchown()
855 int ksys_fchown(unsigned int fd, uid_t user, gid_t group) in ksys_fchown()
865 SYSCALL_DEFINE3(fchown, unsigned int, fd, uid_t, user, gid_t, group) in SYSCALL_DEFINE3() argument
H A Dinternal.h193 int do_fchownat(int dfd, const char __user *filename, uid_t user, gid_t group,
195 int chown_common(const struct path *path, uid_t user, gid_t group);
/linux/usr/
H A Dgen_init_cpio.c109 unsigned int mode, uid_t uid, gid_t gid) in cpio_mkslink()
158 uid_t uid, gid_t gid) in cpio_mkgeneric()
246 uid_t uid, gid_t gid, char dev_type, in cpio_mknod()
324 unsigned int mode, uid_t uid, gid_t gid, in cpio_mkfile()
/linux/tools/include/nolibc/
H A Dstd.h29 typedef unsigned int gid_t; typedef
/linux/fs/bcachefs/
H A Dfs-common.h18 uid_t, gid_t, umode_t, dev_t,
H A Dinode.h157 uid_t, gid_t, umode_t, dev_t,
160 uid_t, gid_t, umode_t, dev_t,
/linux/fs/smb/server/mgmt/
H A Duser_config.h22 gid_t *sgid;
H A Duser_config.c66 resp_ext->ngroups * sizeof(gid_t), in ksmbd_alloc_user()
/linux/fs/smb/server/
H A Dxattr.h69 gid_t gid;
/linux/fs/hostfs/
H A Dhostfs.h49 gid_t ia_gid;
/linux/include/net/
H A Dping.h19 #define GID_T_MAX (((gid_t)~0U) - 1)
/linux/security/keys/
H A Dkeyctl.c949 long keyctl_chown_key(key_serial_t id, uid_t user, gid_t group) in keyctl_chown_key()
964 if ((group != (gid_t) -1) && !gid_valid(gid)) in keyctl_chown_key()
968 if (user == (uid_t) -1 && group == (gid_t) -1) in keyctl_chown_key()
993 if (group != (gid_t) -1 && !gid_eq(gid, key->gid) && !in_group_p(gid)) in keyctl_chown_key()
1045 if (group != (gid_t) -1) in keyctl_chown_key()
1923 (gid_t) arg4); in SYSCALL_DEFINE5()

123