Re: Questions regarding SET option.

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема Re: Questions regarding SET option.
Дата
Msg-id 162867791002220347s33798013icd47724215eadc88@mail.gmail.com
обсуждение исходный текст
Ответ на Questions regarding SET option.  (Jignesh Shah <jignesh.shah1980@gmail.com>)
Список pgsql-general
Hello

you can overwrite standard settings only for function

CREATE [ OR REPLACE ] FUNCTION
    name ( [ [ argmode ] [ argname ] argtype [ { DEFAULT | = }
default_expr ] [, ...] ] )
    [ RETURNS rettype
      | RETURNS TABLE ( column_name column_type [, ...] ) ]
  { LANGUAGE lang_name
    | WINDOW
    | IMMUTABLE | STABLE | VOLATILE
    | CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT
    | [ EXTERNAL ] SECURITY INVOKER | [ EXTERNAL ] SECURITY DEFINER
    | COST execution_cost
    | ROWS result_rows
    | SET configuration_parameter { TO value | = value | FROM CURRENT } <<<===
    | AS 'definition'
    | AS 'obj_file', 'link_symbol'
  } ...
    [ WITH ( attribute [, ...] ) ]

Regards
Pavel Stehule


2010/2/22 Jignesh Shah <jignesh.shah1980@gmail.com>:
> Hello All,
>
> I have been writing a function with SECURITY DEFINER enabled. Basically, I
> am looking for ways to override the users SET option settings while
> executing my function to prevent the permissions breach. For example, to
> override "SET search_path", I am setting search path in my function before
> executing anything. Could any one please tell me what could be other SET
> options that I should take care?
>
> Moreover, how to revert back those settings just before returning from my
> function?
>
> Thanks, Jack

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

Предыдущее
От: beulah prasanthi
Дата:
Сообщение: TypeCast: util.list to array type
Следующее
От: Tino Wildenhain
Дата:
Сообщение: Re: What is unsecure postgres languages? How to disable them?