Re: Extending grant insert on tables to sequences
От | Abhijit Menon-Sen |
---|---|
Тема | Re: Extending grant insert on tables to sequences |
Дата | |
Msg-id | 20080712113041.GA25112@toroid.org обсуждение исходный текст |
Ответ на | Re: Extending grant insert on tables to sequences ("Jaime Casanova" <jcasanov@systemguards.com.ec>) |
Ответы |
Re: Extending grant insert on tables to sequences
|
Список | pgsql-hackers |
At 2008-07-11 11:57:37 -0500, jcasanov@systemguards.com.ec wrote: > > attached is a new version of the patch, it implements Alvaro's > suggestion and fix a bug i found (it wasn't managing GRANT ALL) :( Looks good to me. > About the SELECT issue, AFAIU Robert doesn't complaint he just asked > what is the use case... if people think it should be removed ok, but > OTOH: why? i don't think that affects anything... As I said, I don't feel too strongly about it. > <para> > ! Granting permission on a table automatically extend > ! permissions to any sequences owned by the table, including > ! sequences tied to <type>SERIAL</> columns. > </para> Should be "Granting permissions on a table automatically extends those permissions to...". > + if ((istmt.objtype == ACL_OBJECT_RELATION) && (istmt.all_privs || > + (istmt.privileges & (ACL_INSERT | ACL_UPDATE | ACL_SELECT)))) > + { The parentheses around the first comparison can go away, and also the ones around the ACL_* here: > + if (istmt.privileges & (ACL_INSERT)) > + istmt_seq.privileges |= ACL_USAGE; > + if (istmt.privileges & (ACL_UPDATE)) > + istmt_seq.privileges |= ACL_UPDATE; > + if (istmt.privileges & (ACL_SELECT)) > + istmt_seq.privileges |= ACL_SELECT; -- ams
В списке pgsql-hackers по дате отправления: