Fixed checking static groups against process owner

When grouping of users are determined from /etc/group (a compile-time
option not currently used), the groups examined for checking access rights
to a file were wrongly derived from the uid of the file instead of the
uid of the current process.
edge.strict_endians
Jean-Pierre André 2014-05-22 09:38:47 +02:00
parent 8390ac4dee
commit e8c43f434b
1 changed files with 1 additions and 1 deletions

View File

@ -1980,7 +1980,7 @@ static int access_check_posix(struct SECURITY_CONTEXT *scx,
for (i=pxdesc->acccnt-1; i>=0 ; i--) {
pxace = &pxdesc->acl.ace[i];
if ((pxace->tag == POSIX_ACL_GROUP)
&& groupmember(scx, uid, pxace->id)) {
&& groupmember(scx, scx->uid, pxace->id)) {
if (!(~pxace->perms & request & mask))
groupperms = pxace->perms;
somegroup = TRUE;