Re: Granting SET and ALTER SYSTE privileges for GUCs

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Granting SET and ALTER SYSTE privileges for GUCs
Дата
Msg-id 666648.1647457564@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Granting SET and ALTER SYSTE privileges for GUCs  (Mark Dilger <mark.dilger@enterprisedb.com>)
Ответы Re: Granting SET and ALTER SYSTE privileges for GUCs  (Joshua Brindle <joshua.brindle@crunchydata.com>)
Список pgsql-hackers
Mark Dilger <mark.dilger@enterprisedb.com> writes:
> On Mar 16, 2022, at 11:47 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> ... I therefore judge the
>> hook calls added to ExecSetVariableStmt and AlterSystemSetConfigFile
>> to be 100% useless, in fact probably counterproductive because they
>> introduce a boatload of worries about whether the right things happen
>> if the hook errors out or does something guc.c isn't expecting.

> I think Joshua was planning to use these hooks for security purposes.  The hooks are supposed to check whether the
Oidis valid, and if not, still be able to make choices based on the other information.  Joshua, any comment on this? 

It's going to be hard to do anything useful in a hook that (a) does
not know which GUC is being assigned to and (b) cannot do catalog
accesses for fear that we're not inside a transaction.  (b), in
particular, seems like a rather thorough API break; up to now
ObjectPostAlter hooks could assume that catalog accesses are OK.

            regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Joshua Brindle
Дата:
Сообщение: Re: Granting SET and ALTER SYSTE privileges for GUCs
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: support for MERGE