version 1.13, 2007/07/26 16:10:16 |
version 1.14, 2007/08/02 02:10:07 |
|
|
#endif /* HAVE_EXTENDED_GLOB */ |
#endif /* HAVE_EXTENDED_GLOB */ |
|
|
#ifndef lint |
#ifndef lint |
__unused static const char rcsid[] = "$Sudo: parse.c,v 1.160.2.10 2007/07/06 19:34:20 millert Exp $"; |
__unused static const char rcsid[] = "$Sudo: parse.c,v 1.160.2.11 2007/08/02 02:09:10 millert Exp $"; |
#endif /* lint */ |
#endif /* lint */ |
|
|
/* |
/* |
|
|
struct group *grp; |
struct group *grp; |
gid_t pw_gid; |
gid_t pw_gid; |
char **cur; |
char **cur; |
int n; |
int i; |
|
|
/* make sure we have a valid usergroup, sudo style */ |
/* make sure we have a valid usergroup, sudo style */ |
if (*group++ != '%') |
if (*group++ != '%') |
|
|
/* |
/* |
* If the user has a supplementary group vector, check it first. |
* If the user has a supplementary group vector, check it first. |
*/ |
*/ |
for (n = user_ngroups; n != 0; n--) { |
for (i = 0; i < user_ngroups; i++) { |
if (grp->gr_gid == user_groups[n]) |
if (grp->gr_gid == user_groups[i]) |
return(TRUE); |
return(TRUE); |
} |
} |
if (grp->gr_mem != NULL) { |
if (grp->gr_mem != NULL) { |