Re: Permissions within a function

Поиск
Список
Период
Сортировка
От Peter Eisentraut
Тема Re: Permissions within a function
Дата
Msg-id 200412181015.01219.peter_e@gmx.net
обсуждение исходный текст
Ответ на Re: Permissions within a function  (Thomas Hallgren <thhal@mailblocks.com>)
Ответы Re: Permissions within a function  (Thomas Hallgren <thhal@mailblocks.com>)
Список pgsql-hackers
Thomas Hallgren wrote:
> Is there a way to bypass security checks that retains the SQL parser?
> I'd like my C-code to do something like:
>
> impersonate pgadmin
> SELECT image from class_table
> revert to self

You can use GetUserId() and SetUserId() to flip the current user 
identity around as you like.  For such a simple query, however, it 
might seem better to bypass SPI altogether and do a straight table 
lookup through lower-level functions.

-- 
Peter Eisentraut
http://developer.postgresql.org/~petere/


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

Предыдущее
От: Mike G
Дата:
Сообщение: Re: Dump from cygwin directly to windows
Следующее
От: Christopher Kings-Lynne
Дата:
Сообщение: Re: double error msg [ 8.0 rc1 ]