From: | Petr Jelinek <pjmodos(at)pjmodos(dot)net> |
---|---|
To: | Nikhil Sontakke <nikhil(dot)sontakke(at)enterprisedb(dot)com> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: [PATCH] DefaultACLs |
Date: | 2009-07-17 10:28:37 |
Message-ID: | 4A605255.9020302@pjmodos.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Nikhil Sontakke wrote:
>> There is however one thing that needs some attention. Both patches add
>> distinction between VIEW and TABLE objects for acls into parser and they
>> both do it differently. GRANT ON ALL works by adding ACL_OBJECT_VIEW and
>> tracks that object type in code (that was my original method in both
>> patches) while DefaultACLs uses method suggested by Stephen Frost which is
>> creating new enum with relation, view, function and sequence members (those
>> are object types for which both DefaultACLs and GRANT ON ALL are
>> applicable). The second method has advantage of minimal changes to existing
>> code.
>>
> I briefly looked at the DefaultACLs patch. Can you not re-use the
> GrantStmt structure for the defaults purpose too? You might have to
> introduce an "is_default" boolean similar to the "is_schema" boolean
> that you have added in the "GRANT ON ALL" patch. If you think you can
> re-use the GrantStmt structure, then we might as well stick with the
> existing object type code and not add the enums in the DefaultACLs
> patch too..
>
No we can't use the GrantStmt and I wasn't talking about using it. I was
talking about the change in GrantObjectType and differentiating VIEW and
TABLE in some code inside aclchk.c which people didn't like. We can use
the changed GrantObjectType in DefaultACLs and filter inapplicable types
inside C code as I do in GRANT ON ALL patch and it's what I did
originally, but submitted version of DefaultACLs behaves differently.
--
Regards
Petr Jelinek (PJMODOS)
From | Date | Subject | |
---|---|---|---|
Next Message | Petr Jelinek | 2009-07-17 11:00:04 | Re: GRANT ON ALL IN schema |
Previous Message | Boszormenyi Zoltan | 2009-07-17 10:27:49 | ECPG support for struct in INTO list |