Default privileges for 7.3 - Mailing list pgsql-hackers

From Tom Lane
Subject Default privileges for 7.3
Date
Msg-id 21863.1032794019@sss.pgh.pa.us
Whole thread Raw
In response to HISTORY updated for 7.3beta2  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: Default privileges for 7.3  (Bruce Momjian <pgman@candle.pha.pa.us>)
Re: Default privileges for 7.3  (Peter Eisentraut <peter_e@gmx.net>)
Re: Default privileges for 7.3  (Yury Bokhoncovich <byg@center-f1.ru>)
List pgsql-hackers
Bruce Momjian <pgman@candle.pha.pa.us> writes:
>                           7 . 3  O P E N    I T E M S
>
> Loading 7.2 pg_dumps
>     functions no longer public executable
>     languages no longer public usable


Although it's reasonably easy to fix no-privileges problems for
functions after you load a dump, it occurs to me that the same does not
hold for PL languages.  If a newly created language doesn't have USAGE
available to public, then any function definitions in your dump are
going to fail, if they belong to non-superusers.

I am thinking that the better course might be to have newly created
languages default to USAGE PUBLIC, at least for a release or two.

We might also consider letting newly created functions default to
EXECUTE PUBLIC.  I think this is less essential, but a case could still
be made for it on backwards-compatibility grounds.

If you don't want to hard-wire that behavior, what about a GUC variable
that could be turned on while loading old dumps?

Comments?
        regards, tom lane


pgsql-hackers by date:

Previous
From: Roberto Fichera
Date:
Subject: Re: Problem on PG7.2.2
Next
From: Bruce Momjian
Date:
Subject: Re: Default privileges for 7.3