Re: Remove superuser() checks from pgstattuple - Mailing list pgsql-hackers

From Peter Eisentraut
Subject Re: Remove superuser() checks from pgstattuple
Date
Msg-id 6e01d90c-337f-fc02-2021-6520b4a099b9@2ndquadrant.com
Whole thread Raw
In response to Remove superuser() checks from pgstattuple  (Stephen Frost <sfrost@snowman.net>)
Responses Re: Remove superuser() checks from pgstattuple  (Stephen Frost <sfrost@snowman.net>)
List pgsql-hackers
On 8/23/16 5:22 PM, Stephen Frost wrote:
> Now that we track initial privileges on extension objects and changes to
> those permissions, we can drop the superuser() checks from the various
> functions which are part of the pgstattuple extension.
> 
> Since a pg_upgrade will preserve the version of the extension which
> existed prior to the upgrade, we can't simply modify the existing
> functions but instead need to create new functions which remove the
> checks and update the SQL-level functions to use the new functions

I think this is a good change to pursue, and we'll likely want to do
more similar changes in contrib.  But I'm worried that what is logically
a 10-line change will end up a 20 KiB patch every time.

Have we explored other options for addressing the upgrade problems?
Maybe the function could check that non-default privileges have been
granted?

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services



pgsql-hackers by date:

Previous
From: Fabrízio de Royes Mello
Date:
Subject: Re: PostgreSQL 10 kick-off
Next
From: Anderson Carniel
Date:
Subject: What is the posix_memalign() equivalent for the PostgreSQL?