Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit1e5755c

Browse files
committed
Patch from Massimo Dal Zotto <dz@cs.unitn.it>
The first patch changes the behavior of aclcheck for groups. Currently an usercan access a table only if he has the required permission for ALL the groupsdefined for that table. With my patch he can access a table if he has thepermission for ONE of the groups, which seems to me a more useful thing.If you think this should be the correct behavior of the acl group check feelfree to remove the #ifdef, if not please add a commented line to config.h.
1 parentfa937b5 commit1e5755c

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

‎src/backend/tcop/aclchk.c

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/tcop/Attic/aclchk.c,v 1.5 1996/11/30 18:06:45 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/tcop/Attic/aclchk.c,v 1.6 1997/01/23 19:33:31 scrappy Exp $
1111
*
1212
* NOTES
1313
* See acl.h.
@@ -291,6 +291,12 @@ aclcheck(Acl *acl, AclId id, AclIdType idtype, AclMode mode)
291291
i<num&&aip->ai_idtype==ACL_IDTYPE_GID;
292292
++i,++aip) {
293293
if (in_group(id,aip->ai_id)) {
294+
#ifdefACLGROUP_PATCH
295+
if (aip->ai_mode&mode) {
296+
found_group=1;
297+
break;
298+
}
299+
#else
294300
if (aip->ai_mode&mode)
295301
++found_group;
296302
else {
@@ -300,6 +306,7 @@ aclcheck(Acl *acl, AclId id, AclIdType idtype, AclMode mode)
300306
#endif
301307
return(0);
302308
}
309+
#endif
303310
}
304311
}
305312
if (found_group) {

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp