Re: [PATCH] allow has_table_privilege(..., 'usage') on sequences - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCH] allow has_table_privilege(..., 'usage') on sequences
Date
Msg-id 27603.1220846153@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PATCH] allow has_table_privilege(..., 'usage') on sequences  (Abhijit Menon-Sen <ams@oryx.com>)
Responses Re: [PATCH] allow has_table_privilege(..., 'usage') on sequences  ("Jaime Casanova" <jcasanov@systemguards.com.ec>)
List pgsql-hackers
Abhijit Menon-Sen <ams@oryx.com> writes:
> (I can't help but think that the USAGE privilege is a bit unfortunate.
> If granting SELECT rights allowed currval(), INSERT allowed nextval(),
> and UPDATE allowed nextval() and setval(), then has_table_privilege()
> would have been sufficient and there would be no need to invent a new
> set of functions just to check USAGE.

That train left the station already, and anyway you are failing to
consider "SELECT * FROM sequence", which definitely needs to have
different privileges from nextval()/currval().
        regards, tom lane


pgsql-hackers by date:

Previous
From: Abhijit Menon-Sen
Date:
Subject: Re: [PATCH] allow has_table_privilege(..., 'usage') on sequences
Next
From: "Fujii Masao"
Date:
Subject: Re: For what should pg_stop_backup wait?