Re: BUG #13907: Restore materialized view throw permission denied - Mailing list pgsql-bugs

From Kevin Grittner
Subject Re: BUG #13907: Restore materialized view throw permission denied
Date
Msg-id CACjxUsPUNgVp-VWrcdCDRdupE58TN-GuCfQ_4HJw_Wee1rVa3Q@mail.gmail.com
Whole thread Raw
In response to Re: BUG #13907: Restore materialized view throw permission denied  (Peter Eisentraut <peter.eisentraut@2ndquadrant.com>)
Responses Re: BUG #13907: Restore materialized view throw permission denied
List pgsql-bugs
On Mon, Jul 25, 2016 at 8:37 PM, Peter Eisentraut
<peter.eisentraut@2ndquadrant.com> wrote:
> On 7/25/16 4:09 PM, Kevin Grittner wrote:
>> On Mon, Jun 27, 2016 at 1:35 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>>
>>> I'm planning to apply the attached revision as soon as I get done
>>> back-porting it.
>>
>> I'm thinking of applying something like the attached to fix the
>> rest of this bug.
>
> The reason that ACLs are restored last is that they could contain owner
> self-revokes.  So anything that you run after the ACLs could fail
> because of that.  I think a more complete fix would be to split up the
> ACL restores into the general part, which you would run right after the
> object is restored, and the owner revokes, which you would run last.

So you are suggesting that restoring from pg_dump output should
generate materialized view data under a different security context
than would be used by a REFRESH statement on the source database?

Anything you can add to clarify what you mean by "owner
self-revokes" and why the security should be different when the
matview data is refreshed at the end of the restore should be
different from what would happen on the database which was backed
up might be helpful.

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

pgsql-bugs by date:

Previous
From: John R Pierce
Date:
Subject: Re: Postgresql
Next
From: daeli@cisco.com
Date:
Subject: BUG #14264: Error installing 9.6 beta 3 on Red hat 6.5