/openbsd/lib/libc/gen/ |
H A D | getgrouplist.c | 96 if (i == *ngroups) { in _parse_netid() 97 if (*ngroups >= maxgroups) in _parse_netid() 98 (*ngroups)++; in _parse_netid() 100 groups[(*ngroups)++] = gid; in _parse_netid() 156 if (ngroups >= maxgroups) in getgrouplist() 157 ngroups++; in getgrouplist() 159 groups[ngroups++] = agroup; in getgrouplist() 177 i < ngroups; i++) { in getgrouplist() 185 if (ngroups >= maxgroups) in getgrouplist() 186 ngroups++; in getgrouplist() [all …]
|
H A D | initgroups.c | 40 int maxgroups, ngroups; in initgroups() local 42 maxgroups = ngroups = NGROUPS_MAX; in initgroups() 43 if (getgrouplist(uname, agroup, groups, &ngroups) == -1) { in initgroups() 45 ngroups = maxgroups; in initgroups() 47 if (setgroups(ngroups, groups) == -1) in initgroups()
|
/openbsd/usr.bin/ssh/ |
H A D | groupaccess.c | 40 static int ngroups; variable 54 if (ngroups > 0) in ga_init() 57 maxgroups = ngroups = sizeof(groups_bygid) / sizeof(gid_t); in ga_init() 61 ngroups = maxgroups; in ga_init() 63 for (i = 0, j = 0; i < ngroups; i++) in ga_init() 66 return (ngroups = j); in ga_init() 78 for (i = 0; i < ngroups; i++) in ga_match() 94 for (i = 0; i < ngroups; i++) { in ga_match_pattern_list() 116 if (ngroups > 0) { in ga_free() 117 for (i = 0; i < ngroups; i++) in ga_free() [all …]
|
/openbsd/usr.bin/id/ |
H A D | id.c | 231 int cnt, ngroups; in current() local 272 int cnt, maxgroups, ngroups; in user() local 282 maxgroups = ngroups = NGROUPS_MAX + 1; in user() 285 ngroups = maxgroups; in user() 288 for (cnt = 0; cnt < ngroups;) { in user() 295 while (++cnt < ngroups && gid == groups[cnt]) in user() 304 int cnt, maxgroups, ngroups; in group() local 312 maxgroups = ngroups = NGROUPS_MAX + 1; in group() 316 ngroups = maxgroups; in group() 323 for (cnt = 0; cnt < ngroups;) { in group() [all …]
|
/openbsd/usr.bin/doas/ |
H A D | doas.c | 105 for (i = 0; i < ngroups; i++) { in match() 109 if (i == ngroups) in match() 143 if (match(uid, groups, ngroups, target, cmd, in permit() 183 uid_t uid, gid_t *groups, int ngroups, uid_t target) in checkconfig() argument 194 rv = permit(uid, groups, ngroups, &rule, target, argv[0], in checkconfig() 323 int ngroups; in main() local 380 ngroups = getgroups(NGROUPS_MAX, groups); in main() 381 if (ngroups == -1) in main() 383 groups[ngroups++] = getgid(); in main() 398 checkconfig(confpath, argc, argv, uid, groups, ngroups, in main() [all …]
|
/openbsd/usr.bin/quota/ |
H A D | quota.c | 97 int ngroups; in main() local 132 if (ngroups < 0) in main() 135 for (i = 0; i < ngroups; i++) in main() 227 int ngroups; in showgid() local 238 if (ngroups < 0) { in showgid() 243 for (i = 0; i < ngroups; i++) in showgid() 246 if (i >= ngroups && getuid() != 0) { in showgid() 261 int ngroups; in showgrpname() local 271 if (ngroups < 0) { in showgrpname() 276 for (i = 0; i < ngroups; i++) in showgrpname() [all …]
|
/openbsd/sys/dev/acpi/ |
H A D | pchgpio.c | 54 int ngroups; member 150 .ngroups = nitems(spt_lp_groups), 180 .ngroups = nitems(spt_h_groups), 214 .ngroups = nitems(cnl_h_groups), 243 .ngroups = nitems(cnl_lp_groups), 277 .ngroups = nitems(tgl_lp_groups), 315 .ngroups = nitems(tgl_h_groups), 353 .ngroups = nitems(adl_s_groups), 387 .ngroups = nitems(adl_n_groups), 421 .ngroups = nitems(mtl_p_groups), [all …]
|
/openbsd/lib/libssl/ |
H A D | t1_lib.c | 540 const int *groups, size_t ngroups) in tls1_set_groups() argument 545 if ((group_ids = calloc(ngroups, sizeof(uint16_t))) == NULL) in tls1_set_groups() 548 for (i = 0; i < ngroups; i++) { in tls1_set_groups() 557 *out_group_ids_len = ngroups; in tls1_set_groups() 567 size_t ngroups = 0; in tls1_set_group_list() local 584 if ((new_group_ids = reallocarray(group_ids, ngroups + 1, in tls1_set_group_list() 589 if (!tls1_ec_nid2group_id(nid, &group_ids[ngroups])) in tls1_set_group_list() 592 ngroups++; in tls1_set_group_list() 598 *out_group_ids_len = ngroups; in tls1_set_group_list()
|
/openbsd/usr.sbin/lpr/lpc/ |
H A D | lpc.c | 281 static int ngroups; in ingroup() local 290 if ((ngroups = getgroups(NGROUPS_MAX, groups)) < 0) in ingroup() 294 for (i = 0; i < ngroups; i++) in ingroup()
|
/openbsd/regress/sys/ffs/ |
H A D | fstest.c | 428 long ngroups; in set_gids() local 432 ngroups = sysconf(_SC_NGROUPS_MAX); in set_gids() 433 assert(ngroups > 0); in set_gids() 434 gidset = reallocarray(NULL, ngroups, sizeof(*gidset)); in set_gids() 438 if (i >= ngroups) { in set_gids()
|
/openbsd/gnu/usr.bin/cvs/windows-NT/ |
H A D | pwd.h | 56 extern int ngroups;
|
H A D | pwd.c | 166 getgroups (int ngroups, int *groups) in getgroups() argument
|
/openbsd/gnu/usr.bin/cvs/os2/ |
H A D | pwd.h | 56 extern int ngroups;
|
H A D | pwd.c | 159 getgroups (int ngroups, int *groups) in getgroups() argument
|
/openbsd/usr.sbin/authpf/ |
H A D | authpf.c | 494 int gl_init = 0, ngroups = NGROUPS_MAX + 1; in allowed_luser() local 533 maxgroups = ngroups; in allowed_luser() 535 pw->pw_gid, groups, &ngroups); in allowed_luser() 540 ngroups = maxgroups; in allowed_luser() 545 for ( cnt = 0; cnt < ngroups; cnt++) { in allowed_luser()
|
/openbsd/usr.sbin/tcpdump/ |
H A D | print-icmp6.c | 746 u_int group, nsrcs, ngroups; in mldv2_report_print() local 755 ngroups = ntohs(icp->icmp6_data16[1]); in mldv2_report_print() 756 printf(", %d group record(s)", ngroups); in mldv2_report_print() 760 for (i = 0; i < ngroups; i++) { in mldv2_report_print()
|
/openbsd/sys/nfs/ |
H A D | nfs_subs.c | 555 int i, authsiz, auth_len, ngroups; in nfsm_rpchead() local 579 ngroups = req->r_nmp->nm_numgrps; in nfsm_rpchead() 581 ngroups = cr->cr_ngroups; in nfsm_rpchead() 583 auth_len = (ngroups << 2) + 5 * NFSX_UNSIGNED; in nfsm_rpchead() 620 *tl++ = txdr_unsigned(ngroups); in nfsm_rpchead() 621 for (i = 0; i < ngroups; i++) in nfsm_rpchead()
|
/openbsd/sys/dev/pci/ |
H A D | azalia.c | 2657 if (this->dacs.ngroups > 0 && newdac < this->dacs.ngroups && in azalia_codec_construct_format() 2682 if (this->adcs.ngroups > 0 && newadc < this->adcs.ngroups && in azalia_codec_construct_format() 2724 if (this->dacs.ngroups > 0) { in azalia_codec_construct_format() 2743 if (this->adcs.ngroups > 0) { in azalia_codec_construct_format() 3004 for (i = 0; i < this->adcs.ngroups; i++) { in azalia_widget_sole_conn() 3014 for (i = 0; i < this->dacs.ngroups; i++) { in azalia_widget_sole_conn() 3114 if (codec->dacs.ngroups < 1) in azalia_widget_label_widgets() 3126 if (codec->dacs.ngroups < 2) in azalia_widget_label_widgets() 3142 if (codec->adcs.ngroups < 1) in azalia_widget_label_widgets() 3154 if (codec->adcs.ngroups < 2) in azalia_widget_label_widgets() [all …]
|
H A D | if_iwnreg.h | 1105 uint8_t ngroups; member 1112 uint8_t ngroups; member 1122 uint8_t ngroups; member 1133 uint8_t ngroups; member 1144 uint8_t ngroups; member
|
H A D | azalia_codec.c | 585 this->dacs.ngroups = 0; in azalia_init_dacgroup() 598 this->adcs.ngroups = 0; in azalia_init_dacgroup() 684 group->groups[group->ngroups].conv[i] = convs[i]; in azalia_add_convgroup() 686 group->groups[group->ngroups].nconv = i; in azalia_add_convgroup() 687 group->ngroups++; in azalia_add_convgroup() 1382 if (this->dacs.ngroups > 1) { in azalia_mixer_init() 1402 if (this->adcs.ngroups > 1) { in azalia_mixer_init() 2199 if (mc->un.ord >= this->dacs.ngroups) in azalia_mixer_set() 2212 if (mc->un.ord >= this->adcs.ngroups) in azalia_mixer_set()
|
H A D | azalia.h | 627 int ngroups; member
|
/openbsd/sys/ufs/ext2fs/ |
H A D | ext2fs_vfsops.c | 657 int i, ngroups; in ext2fs_statfs() local 673 for (i = 0, ngroups = 0; i < fs->e2fs_ncg; i++) { in ext2fs_statfs() 675 ngroups++; in ext2fs_statfs() 678 ngroups = fs->e2fs_ncg; in ext2fs_statfs() 680 overhead += ngroups * (1 + fs->e2fs_ngdb); in ext2fs_statfs()
|
/openbsd/usr.sbin/nsd/ |
H A D | zonec.c | 394 int ngroups, num; in zparser_conv_ilnp64() local 401 ngroups = 1; /* Always at least one group */ in zparser_conv_ilnp64() 413 ui[ngroups - 1] = hex; in zparser_conv_ilnp64() 414 if (ngroups >= ILNP_NUMGROUPS) { in zparser_conv_ilnp64() 419 ngroups++; in zparser_conv_ilnp64() 443 ui[ngroups - 1] = hex; in zparser_conv_ilnp64() 444 if (ngroups < 4) { in zparser_conv_ilnp64()
|
/openbsd/sbin/mountd/ |
H A D | mountd.c | 2175 int maxgroups, ngroups, cnt; in parsecred() local 2200 maxgroups = ngroups = NGROUPS_MAX + 1; in parsecred() 2201 if (getgrouplist(pw->pw_name, pw->pw_gid, groups, &ngroups) == -1) { in parsecred() 2204 ngroups = maxgroups; in parsecred() 2209 cr->cr_ngroups = ngroups - 1; in parsecred() 2211 for (cnt = 1; cnt < ngroups; cnt++) in parsecred()
|
/openbsd/usr.sbin/pppd/ |
H A D | options.c | 693 int ngroups, i; in readable() local 706 ngroups = getgroups(NGROUPS_MAX, groups); in readable() 707 for (i = 0; i < ngroups; ++i) in readable()
|