]> granicus.if.org Git - sudo/commitdiff
Resolve the list of gids passed in from the sudo frontend (the
authorTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 1 Jul 2011 18:21:06 +0000 (14:21 -0400)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Fri, 1 Jul 2011 18:21:06 +0000 (14:21 -0400)
result of getgroups()) to names and store both the group names and
ids in the sudo_user struct.  When matching groups in the sudoers
file, match based on the names in the groups list first and
only do a gid-based match when we absolutely have to.  By matching
on the group name (as it is listed in sudoers) instead of id
(which we would have to resolve) we save a lot of group lookups
for sudoers files with a lot of groups in them.

--HG--
branch : 1.8


Trivial merge