/titanic_41/usr/src/lib/libcmdutils/common/ |
H A D | gid.c | 41 static boolean_t isreservedgid(gid_t gid); 50 gid_t gid = start; in findnextgid() local 58 if (grp->gr_gid >= gid) { in findnextgid() 63 gid = grp->gr_gid + 1; in findnextgid() 73 while (isreservedgid(gid) && gid < stop) /* Skip reserved IDs */ in findnextgid() 74 gid++; in findnextgid() 75 *ret = gid; in findnextgid() 84 isreservedgid(gid_t gid) in isreservedgid() argument 86 return (gid == 60001 || gid == 60002 || gid == 65534); in isreservedgid() 96 gid_t gid; in findunusedgid() local [all …]
|
/titanic_41/usr/src/uts/common/sys/ib/clients/of/rdma/ |
H A D | ib_addr.h | 79 union ib_gid *gid) in ib_addr_get_mgid() argument 81 (void) memcpy(gid, dev_addr->broadcast + 4, sizeof (*gid)); in ib_addr_get_mgid() 85 union ib_gid *gid) in ib_addr_get_sgid() argument 87 (void) memcpy(gid, dev_addr->src_dev_addr + 4, sizeof (*gid)); in ib_addr_get_sgid() 91 union ib_gid *gid) in ib_addr_set_sgid() argument 93 (void) memcpy(dev_addr->src_dev_addr + 4, gid, sizeof (*gid)); in ib_addr_set_sgid() 97 union ib_gid *gid) in ib_addr_get_dgid() argument 99 (void) memcpy(gid, dev_addr->dst_dev_addr + 4, sizeof (*gid)); in ib_addr_get_dgid() 103 union ib_gid *gid) in ib_addr_set_dgid() argument 105 (void) memcpy(dev_addr->dst_dev_addr + 4, gid, sizeof (*gid)); in ib_addr_set_dgid()
|
/titanic_41/usr/src/lib/libc/port/sys/ |
H A D | chown.c | 36 fchownat(int fd, const char *name, uid_t uid, gid_t gid, int flags) in fchownat() argument 38 return (syscall(SYS_fchownat, fd, name, uid, gid, flags)); in fchownat() 43 chown(const char *name, uid_t uid, gid_t gid) in chown() argument 46 return (syscall(SYS_chown, name, uid, gid)); in chown() 48 return (fchownat(AT_FDCWD, name, uid, gid, 0)); in chown() 54 lchown(const char *name, uid_t uid, gid_t gid) in lchown() argument 57 return (syscall(SYS_lchown, name, uid, gid)); in lchown() 59 return (fchownat(AT_FDCWD, name, uid, gid, AT_SYMLINK_NOFOLLOW)); in lchown() 65 fchown(int filedes, uid_t uid, gid_t gid) in fchown() argument 68 return (syscall(SYS_fchown, filedes, uid, gid)); in fchown() [all …]
|
/titanic_41/usr/src/uts/common/syscall/ |
H A D | gid.c | 44 setgid(gid_t gid) in setgid() argument 54 if (!VALID_GID(gid, zone)) in setgid() 57 if (gid > MAXUID) { in setgid() 58 if (ksid_lookupbygid(zone, gid, &ksid) != 0) in setgid() 79 if ((gid == cr->cr_rgid || gid == cr->cr_sgid) && in setgid() 88 newcr->cr_gid = gid; in setgid() 100 if (cr->cr_gid != gid || in setgid() 101 cr->cr_rgid != gid || in setgid() 102 cr->cr_sgid != gid) in setgid() 106 newcr->cr_gid = gid; in setgid() [all …]
|
H A D | chown.c | 58 fchownat(int fd, char *path, uid_t uid, gid_t gid, int flag) in fchownat() argument 65 gid != (gid_t)-1 && !VALID_GID(gid, zone)) { in fchownat() 69 vattr.va_gid = gid; in fchownat() 83 chown(char *path, uid_t uid, gid_t gid) in chown() argument 85 return (fchownat(AT_FDCWD, path, uid, gid, 0)); in chown() 89 lchown(char *path, uid_t uid, gid_t gid) in lchown() argument 91 return (fchownat(AT_FDCWD, path, uid, gid, AT_SYMLINK_NOFOLLOW)); in lchown() 95 fchown(int fd, uid_t uid, uid_t gid) in fchown() argument 97 return (fchownat(fd, NULL, uid, gid, 0)); in fchown()
|
/titanic_41/usr/src/lib/libcmd/common/ |
H A D | chgrp.c | 119 int gid; /* gid */ member 150 lchown(const char* path, uid_t uid, gid_t gid) in lchown() argument 169 key->uid = key->gid = NOID; in getids() 208 key->gid = n; in getids() 227 int gid; in b_chgrp() local 293 gid = st.st_gid; in b_chgrp() 349 m->to.uid = m->to.gid = NOID; in b_chgrp() 356 keys[1].gid = keys[2].uid = NOID; in b_chgrp() 363 if ((gid = key.gid) != NOID) in b_chgrp() 396 uid = gid = NOID; in b_chgrp() [all …]
|
/titanic_41/usr/src/cmd/chgrp/ |
H A D | chgrp.c | 68 static gid_t gid; variable 203 if (sid_to_id(argv[0], B_FALSE, &gid)) { in main() 209 gid = gr->gr_gid; in main() 214 gid = (gid_t)strtoul(argv[0], NULL, 10); in main() 248 LCHOWN(argv[c], -1, gid); in main() 275 chgrpr(argv[c], gid); in main() 301 CHOWN(argv[c], -1, gid); in main() 308 CHOWN(argv[c], -1, gid); in main() 325 chgrpr(argv[c], gid); in main() 343 LCHOWN(argv[c], -1, gid); in main() [all …]
|
/titanic_41/usr/src/cmd/chown/ |
H A D | chown.c | 63 static gid_t gid = (gid_t)-1; variable 204 if (sid_to_id(grpp, B_FALSE, &gid)) { in main() 211 gid = grp->gr_gid; in main() 215 gid = (gid_t)strtoul(grpp, NULL, 10); in main() 279 LCHOWN(argv[c], uid, gid); in main() 308 uid, gid); in main() 326 CHOWN(argv[c], uid, gid); in main() 333 CHOWN(argv[c], uid, gid); in main() 343 chownr(argv[c], uid, gid); in main() 356 LCHOWN(argv[c], uid, gid); in main() [all …]
|
/titanic_41/usr/src/cmd/oamuser/lib/ |
H A D | vgid.c | 48 valid_gid( gid, gptr ) in valid_gid() argument 49 gid_t gid; in valid_gid() 54 if( gid < 0 ) return( INVALID ); 56 if( gid > MAXUID ) return( TOOBIG ); 58 if( t_gptr = getgrgid( gid ) ) { 63 if( gid <= DEFGID ) { 64 if( gptr ) *gptr = getgrgid( gid );
|
/titanic_41/usr/src/cmd/sendmail/libsm/ |
H A D | t-sem.c | 131 drop_priv(uid, gid) in drop_priv() argument 133 gid_t gid; 137 r = setgid(gid); 158 semtest(owner, uid, gid) in semtest() argument 161 gid_t gid; 168 r = drop_priv(uid, gid); 186 r = sm_semsetowner(semid, uid, gid, 0660); 192 r = drop_priv(uid, gid); 327 gid_t gid; local 330 gid = 0; [all …]
|
/titanic_41/usr/src/uts/common/io/ib/ibtl/ |
H A D | ibtl_cm.c | 178 ibtl_cm_get_hca_port(ib_gid_t gid, ib_guid_t hca_guid, in ibtl_cm_get_hca_port() argument 193 gid.gid_prefix, gid.gid_guid, hca_guid); in ibtl_cm_get_hca_port() 195 if ((gid.gid_prefix == 0) || (gid.gid_guid == 0)) { in ibtl_cm_get_hca_port() 204 (gid.gid_guid == fast_gid.gid_guid) && in ibtl_cm_get_hca_port() 205 (gid.gid_prefix == fast_gid.gid_prefix)) { in ibtl_cm_get_hca_port() 245 if ((gid.gid_guid != sgid->gid_guid) || in ibtl_cm_get_hca_port() 246 (gid.gid_prefix != sgid->gid_prefix)) in ibtl_cm_get_hca_port() 253 fast_gid = gid; in ibtl_cm_get_hca_port() 294 ib_gid_t gid; in ibtl_cm_get_cnt() local 354 gid = pinfop->p_sgid_tbl[j]; in ibtl_cm_get_cnt() [all …]
|
/titanic_41/usr/src/lib/libast/common/string/ |
H A D | fmtgid.c | 60 fmtgid(int gid) in fmtgid() argument 76 else if (ip = (Id_t*)dtmatch(dict, &gid)) in fmtgid() 78 if (gr = getgrgid(gid)) in fmtgid() 86 else if (gid == 0) in fmtgid() 90 name = fmtbuf(z = sizeof(gid) * 3 + 1); in fmtgid() 91 sfsprintf(name, z, "%I*d", sizeof(gid), gid); in fmtgid() 95 ip->id = gid; in fmtgid()
|
/titanic_41/usr/src/cmd/fs.d/smbclnt/chacl/ |
H A D | chacl.c | 76 gid_t gid = (gid_t)-1; in main() local 100 gid = (gid_t)tl; in main() 146 if (gid != (gid_t)-1) in main() 152 chacl(argv[optind], selector, uid, gid, acl); in main() 160 chacl(char *file, uint32_t selector, uid_t uid, gid_t gid, acl_t *acl) in chacl() argument 178 if (uid == (uid_t)-1 || gid == (gid_t)-1) { in chacl() 190 if (gid == (gid_t)-1) in chacl() 191 gid = st.st_gid; in chacl() 197 error = smbfs_acl_zfs2sd(acl, uid, gid, selector, &sd); in chacl() 213 if (gid == (gid_t)-1) in chacl() [all …]
|
/titanic_41/usr/src/cmd/ssh/libopenbsd-compat/common/ |
H A D | bsd-getpeereid.c | 40 getpeereid(int s, uid_t *euid, gid_t *gid) in getpeereid() argument 48 *gid = cred.gid; in getpeereid() 54 getpeereid(int s, uid_t *euid, gid_t *gid) in getpeereid() argument 62 if ((*gid = ucred_getrgid(ucred)) == (gid_t)-1) in getpeereid() 71 getpeereid(int s, uid_t *euid, gid_t *gid) in getpeereid() argument 74 *gid = getgid(); in getpeereid()
|
/titanic_41/usr/src/lib/pam_modules/dhkeys/ |
H A D | key_call_uid.c | 52 authsys_create_uid(uid_t uid, gid_t gid) in authsys_create_uid() argument 64 res = authsys_create(host, uid, gid, 0, (gid_t *)NULL); in authsys_create_uid() 78 xdrproc_t xdr_rslt, char *rslt, uid_t uid, gid_t gid) in my_key_call() argument 131 clnt->cl_auth = authsys_create_uid(uid, gid); in my_key_call() 143 key_setnet_uid(struct key_netstarg *arg, uid_t uid, gid_t gid) in key_setnet_uid() argument 148 (char *)arg, xdr_keystatus, (char *)&status, uid, gid)) { in key_setnet_uid() 161 uid_t uid, gid_t gid) in key_setnet_g_uid() argument 215 return (key_setnet_uid(&tmp, uid, gid)); in key_setnet_g_uid() 219 (char *)&arg, xdr_keystatus, (char *)&status, uid, gid)) { in key_setnet_g_uid() 236 key_secretkey_is_set_uid(uid_t uid, gid_t gid) in key_secretkey_is_set_uid() argument [all …]
|
/titanic_41/usr/src/cmd/ypcmd/mknetid/ |
H A D | mknetid.c | 167 int uid, gid; local 189 gid = Atoi(name); 190 put_d(gid); 193 gid = Atoi(name); 195 put_d(gid); 214 int gid; local 225 gid = Atoi(name); 228 storegid(gid, name); 246 int uid, gid; local 267 gid = Atoi(name); [all …]
|
/titanic_41/usr/src/lib/udapl/udapl_tavor/common/ |
H A D | dapl_name_service.c | 122 ib_gid_t gid; in dapli_ns_create_gid_map() local 137 &gid.gid_prefix, &gid.gid_guid); in dapli_ns_create_gid_map() 166 gmt.gid.gid_prefix = gid.gid_prefix; in dapli_ns_create_gid_map() 167 gmt.gid.gid_guid = gid.gid_guid; in dapli_ns_create_gid_map() 171 &gid.gid_prefix, &gid.gid_guid); in dapli_ns_create_gid_map() 237 OUT ib_gid_t *gid) in dapls_ns_lookup_address() argument 248 gid->gid_guid = gmt->gid.gid_guid; in dapls_ns_lookup_address() 249 gid->gid_prefix = gmt->gid.gid_prefix; in dapls_ns_lookup_address() 308 OUT ib_gid_t *gid); 314 OUT ib_gid_t *gid); [all …]
|
/titanic_41/usr/src/ucbcmd/chown/ |
H A D | chown.c | 69 gid_t gid; in main() local 100 gid = -1; in main() 107 gid = grp -> gr_gid; in main() 111 gid = (gid_t)strtol(group, NULL, 10); in main() 144 status += chownr(argv[c], uid, gid); in main() 147 if (lchown(argv[c], uid, gid)) { in main() 167 chownr(char *dir, uid_t uid, gid_t gid) in chownr() argument 180 if (chown(dir, uid, gid) < 0 && Perror(dir)) in chownr() 201 ecode = chownr(dp->d_name, uid, gid); in chownr() 206 if (lchown(dp->d_name, uid, gid) < 0 && in chownr()
|
/titanic_41/usr/src/cmd/oamuser/group/ |
H A D | groupadd.c | 65 gid_t gid; /* group id */ in main() local 110 gid = (gid_t)strtol(gidstr, &ptr, 10); in main() 117 switch (valid_gid(gid, NULL)) { in main() 119 errmsg(M_RESERVED, gid); in main() 134 errmsg(M_TOOBIG, gid); in main() 141 if (findnextgid(DEFRID+1, MAXUID, &gid) != 0) { in main() 148 if ((rc = add_group(grpname, gid)) != EX_SUCCESS) in main()
|
H A D | groupmod.c | 64 gid_t gid; /* group id */ in main() local 103 gid = (gid_t)strtol(gidstr, &ptr, 10); in main() 110 switch (valid_gid(gid, NULL)) { in main() 112 errmsg(M_RESERVED, gid); in main() 128 errmsg(M_TOOBIG, gid); in main() 134 } else gid = -1; in main() 149 if ((valret = mod_group(grpname, gid, newname)) != EX_SUCCESS) { in main()
|
/titanic_41/usr/src/cmd/id/ |
H A D | id.c | 73 gid_t gid, egid, prgid; in main() local 152 prgid = gid = egid = pwp->pw_gid; in main() 155 gid = getgid(); in main() 163 gid = egid; in main() 168 pgid(gid); in main() 170 pgid(gid); in main() 180 if ((gid = groupids[j]) == egid) in main() 183 pgid(gid); in main() 190 prid(GID, gid); in main() 193 if (gid != egid) in main() [all …]
|
/titanic_41/usr/src/lib/nsswitch/nis/common/ |
H A D | getgrent.c | 59 if (argp->key.gid > MAXUID) 61 (void) snprintf(gidstr, 12, "%d", argp->key.gid); 72 ulong_t gid; in validate_group_ids() local 91 gid = strtoul(gidp, (char **)&linep, 10); /* grab gid */ in validate_group_ids() 96 if (gid <= MAXUID) in validate_group_ids() 190 add_gid(gid_t gid_array[], int numgids, gid_t gid) in add_gid() argument 195 if (gid_array[i] == gid) { in add_gid() 199 gid_array[numgids++] = gid; in add_gid() 214 gid_t gid; in parse_netid() local 238 gid = (gid_t)value; in parse_netid() [all …]
|
/titanic_41/usr/src/lib/nsswitch/ad/common/ |
H A D | getgrent.c | 31 const char *name, const char *domain, gid_t gid) in update_buffer() argument 39 buflen = snprintf(NULL, 0, "%s@%s::%u:", name, domain, gid) + 1; in update_buffer() 53 (void) snprintf(buffer, buflen, "%s@%s::%u:", name, domain, gid); in update_buffer() 72 gid_t gid; in getbynam() local 93 0, &is_user, &is_wuser, &gid, NULL, NULL, NULL); in getbynam() 100 if (update_buffer(be, argp, name, dname, gid) < 0) in getbynam() 127 if (argp->key.gid <= MAXUID) in getbygid() 131 if (idmap_get_u2w_mapping(&argp->key.gid, NULL, 0, in getbygid() 146 if (update_buffer(be, argp, winname, windomain, argp->key.gid) < 0) in getbygid()
|
/titanic_41/usr/src/lib/libidmap/common/ |
H A D | idmap_cache.h | 56 gid_t *gid); 68 gid_t gid); 74 idmap_cache_lookup_winnamebygid(char **winname, char **windomain, gid_t gid); 82 gid_t *gid); 89 idmap_cache_add_sid2gid(const char *sid_prefix, idmap_rid_t rid, gid_t gid, 102 gid_t gid, int direction);
|
/titanic_41/usr/src/lib/libbc/libc/sys/common/ |
H A D | getgid.c | 32 int gid; in getgid() local 34 if ((gid = _getgid()) > 0xffff) in getgid() 35 gid = 60001; /* nobody */ in getgid() 36 return (gid); in getgid()
|