Re: [v9.4] row level security - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [v9.4] row level security
Date
Msg-id 11101.1383575839@sss.pgh.pa.us
Whole thread Raw
In response to Re: [v9.4] row level security  (Craig Ringer <craig@2ndquadrant.com>)
Responses Re: [v9.4] row level security  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
Craig Ringer <craig@2ndquadrant.com> writes:
> On 09/04/2013 11:22 PM, Tom Lane wrote:
>> AFAICT, to deal with update/delete the RLS patch needs to constrain order
>> of qual application without the crutch of having a separate level of
>> subquery; and it's that behavior that I have zero confidence in, either
>> as to whether it works as submitted or as to our odds of not breaking it
>> in the future.

> Wouldn't CASE do that job, albeit in a somewhat ugly manner, and also
> protect against malicious RLS functions?

You mean wrap all the query quals in a CASE?  Sure, if you didn't mind
totally destroying any optimization possibilities.  If you did that,
every table scan would become a seqscan and every join a nestloop.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Removal of archive in wal_level
Next
From: Tom Lane
Date:
Subject: Re: [BUGS] BUG #8573: int4range memory consumption