From: | "Brightwell, Adam" <adam(dot)brightwell(at)crunchydatasolutions(dot)com> |
---|---|
To: | PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Stephen Frost <stephen(dot)frost(at)crunchydatasolutions(dot)com>, Greg Smith <greg(dot)smith(at)crunchydatasolutions(dot)com> |
Cc: | Paul Laurence <paul(dot)laurence(at)crunchydatasolutions(dot)com> |
Subject: | New Model For Role Attributes and Fine Grained Permssions |
Date: | 2014-08-19 01:27:10 |
Message-ID: | CAKRt6CQv-X-cHFn5hg2iHkyipHOphWnRHM6McrG=-vqbmWxYTA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi All,
This is a "proof-of-concept" patch for a new model around role attributes
and fine grained permissions meant to alleviate the current over dependence
on superuser.
This is not yet complete and only serves as a proof-of-concept at this
point, but I wanted to share it in the hopes of receiving comments,
suggestions and general feedback.
The general gist of this patch is as follows:
* New system catalog "pg_permission" that relates role id's to permissions.
* New syntax.
- GRANT <permission> TO <role>
- REVOKE <permission> FROM <role>
where, <permission> is one of an enumerated value, such as "CREATE ROLE" or
"CREATE DATABASE".
* Refactor CREATEDB and NOCREATEDB role attribute to "CREATE DATABASE"
permission set by GRANT or REVOKE.
* Refactor CREATEROLE and NOCREATEROLE role attribute to "CREATE ROLE"
permission set by GRANT or REVOKE.
Again, this is meant to serve as a proof-of-concept. It is not
comprehensive and only demonstrates how this might work with a few already
defined permissions.
I have attached the current patch based on master.
Any comments or feedback would be greatly appreciated.
Thanks,
Adam
--
Adam Brightwell - adam(dot)brightwell(at)crunchydatasolutions(dot)com
Database Engineer - www.crunchydatasolutions.com
Attachment | Content-Type | Size |
---|---|---|
superuser_8-18-2014.patch | text/x-patch | 23.2 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Brightwell, Adam | 2014-08-19 02:19:09 | Re: RLS Design |
Previous Message | furuyao | 2014-08-19 00:52:39 | Re: pg_receivexlog --status-interval add fsync feedback |