Re: [PATCH] DefaultACLs - Mailing list pgsql-hackers

From Robert Haas
Subject Re: [PATCH] DefaultACLs
Date
Msg-id 603c8f070909281927p539c0b58saea9d08816705811@mail.gmail.com
Whole thread Raw
In response to Re: [PATCH] DefaultACLs  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: [PATCH] DefaultACLs
List pgsql-hackers
On Mon, Sep 28, 2009 at 1:32 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> The generic issue that the code doesn't even think about addressing
> is which default should apply when there's potentially more than one
> applicable default?  As long as there's only global and per-schema
> defaults, it's not too hard to decide that the latter take precedence
> over the former; but I have no idea what we're going to do in order
> to add any other features.  This seems like a sufficiently big
> conceptual issue that it had better be resolved now, even if the first
> version of the patch doesn't really need to deal with it.

I haven't read the patch, but it seems like one possible solution to
this problem would be to declare that any any DEFAULT PRIVILEGES you
set are cumulative.  If you configure a global default, a per-schema
default, a default for tables whose names begin with the letter q, and
a default for tables created between midnight and 4am, then a table
called quux created in that schema at 2:30 in the morning will get the
union of all four sets of privileges.

...Robert


pgsql-hackers by date:

Previous
From: KaiGai Kohei
Date:
Subject: Re: [PATCH] Reworks for Access Control facilities (r2311)
Next
From: Euler Taveira de Oliveira
Date:
Subject: Re: Buffer usage in EXPLAIN and pg_stat_statements (review)