| От | Nico Williams |
|---|---|
| Тема | Re: SET ROLE x NO RESET |
| Дата | |
| Msg-id | ZZXwe/DzMqhFCDai@ubby обсуждение исходный текст |
| Ответ на | SET ROLE x NO RESET (Eric Hanson <eric@aquameta.com>) |
| Список | pgsql-hackers |
On Sat, Dec 30, 2023 at 10:16:59AM -0600, Eric Hanson wrote: > What do you think of adding a NO RESET option to the SET ROLE command? I've wanted this forever. Consider using this to implement user authentication mechanisms in user-defined SQL functions that use `SET ROLE` with `NO RESET` to "login" the user. One could implement JWT (or whatever bearer token schemes) on the server side in PlPgSQL w/ pgcrypto this way, with zero changes to PG itself, no protocol changes, etc. For bearer token schemes one could acquire the token externally to the client and then just `SELECT login(?)`, bind the token, and execute to login. Nico --
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера