Re: [COMMITTERS] pgsql: Row-Level Security Policies (RLS)

From: Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com>
To: Joe Conway <mail(at)joeconway(dot)com>
Cc: Stephen Frost <sfrost(at)snowman(dot)net>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [COMMITTERS] pgsql: Row-Level Security Policies (RLS)
Date: 2015-07-30 13:52:18
Message-ID: CAEZATCXXedKjZCwrkXd6hixx6_YS11XiB62Uybsno-D_nfw8Uw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

On 30 July 2015 at 01:35, Joe Conway <mail(at)joeconway(dot)com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 06/01/2015 02:21 AM, Dean Rasheed wrote:
>> While going through this, I spotted another issue --- in a DML
>> query with additional non-target relations, such as UPDATE t1 ..
>> FROM t2 .., the old code was checking the UPDATE policies of both
>> t1 and t2, but really I think it ought to be checking the SELECT
>> policies of t2 (in the same way as this query requires SELECT table
>> permissions on t2, not UPDATE permissions). I've changed that and
>> added new regression tests to test that change.
>
> I assume the entire refactoring patch needs a fair bit of work to
> rebase against current HEAD,

Actually, there haven't been any conflicting changes so far, so a git
rebase was able to automatically merge correctly -- new patch
attached, with some minor comment rewording (not affecting the bug-fix
part).

Even so, I agree that it makes sense to apply the bug-fix separately,
since it's not really anything to do with the refactoring.

> but I picked out the attached to address
> just the above issue. Does this look correct, and if so does it make
> sense to apply at least this part right now?
>

Looks correct to me.

Thanks.

Regards,
Dean

Attachment Content-Type Size
rls-refactoring.patch text/x-patch 49.0 KB

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2015-07-30 16:11:45 pgsql: Avoid some zero-divide hazards in the planner.
Previous Message Heikki Linnakangas 2015-07-30 11:51:31 pgsql: Fix calculation of latency of pgbench backslash commands.

Browse pgsql-hackers by date

  From Date Subject
Next Message Petr Jelinek 2015-07-30 13:58:44 Re: creating extension including dependencies
Previous Message Tomas Vondra 2015-07-30 13:47:59 Re: multivariate statistics / patch v7