Re: Position of ClientAuthentication hook

Поиск
Список
Период
Сортировка
От Robert Haas
Тема Re: Position of ClientAuthentication hook
Дата
Msg-id CA+TgmoZKuQO6D4zbX8HZu2xco48aW5fRMB-gLYawf-edubAGKA@mail.gmail.com
обсуждение исходный текст
Ответ на Position of ClientAuthentication hook  (Rafia Sabih <rafia.pghackers@gmail.com>)
Ответы Re: Position of ClientAuthentication hook  (Rafia Sabih <rafia.pghackers@gmail.com>)
Список pgsql-hackers
On Mon, Jun 14, 2021 at 8:51 AM Rafia Sabih <rafia.pghackers@gmail.com> wrote:
> I have a doubt regarding the positioning of clientAuthentication hook
> in function ClientAuthentication. Particularly, in case of hba errors,
> i.e. cases uaReject or uaImplicitReject it errors out, leading to no
> calls to any functions attached to the authentication hook. Can't we
> process the hook function first and then error out...?

Maybe. One potential problem is that if the hook errors out, the
original error would be lost and only the error thrown by the hook
would be logged or visible to the client. Whether or not that's a
problem depends, I suppose, on what you're trying to do with the hook.

-- 
Robert Haas
EDB: http://www.enterprisedb.com



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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: PG 14 release notes, first draft
Следующее
От: Robert Haas
Дата:
Сообщение: Re: Race condition in recovery?