Re: Limiting user from changing its own attributes

Поиск
Список
Период
Сортировка
От Jim Nasby
Тема Re: Limiting user from changing its own attributes
Дата
Msg-id 552B397F.5010604@BlueTreble.com
обсуждение исходный текст
Ответ на Re: Limiting user from changing its own attributes  (Sameer Kumar <sameer.kumar@ashnik.com>)
Ответы Re: Limiting user from changing its own attributes  (Sameer Kumar <sameer.kumar@ashnik.com>)
Список pgsql-general
On 4/11/15 4:11 PM, Sameer Kumar wrote:
>     Pg_settings currently has an upper bound column - though it is a
>     view and that value cannot be changed that I know of.
>
>
> I guess that upper bound column is more of the limit that is imposed by
> system which you can have for a parameter i.e. the system imposed limit
> or valid range if values for a parameter. I don't think one can update that.

Correct.

>     But if it could I suspect that whatever catalog you would change to
>     affect it would only cause a global change. There is no alter
>     database, role, or postgresql way to change that value.
>
> Oh ok... anyway of achieving that? There no EVENT trigger for "alter user"?

There is not, but as David mentioned there's way more ways to modify
settings than just ALTER ROLE. Attempting to lock that down won't help
you at all.

Unfortunately, there's no hook support for doing something special when
GUCs change, though it might be possible to do something here via
planner hooks. That would be pretty complicated and would need to be
done in C.

It doesn't look like SELinux would help either.

So basically, there is currently no way to restrict someone changing
GUCs, other than GUCs that are marked as superuser-only.
--
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com


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

Предыдущее
От: Michael Cheung
Дата:
Сообщение: Re: schema or database
Следующее
От: Sameer Kumar
Дата:
Сообщение: Re: Limiting user from changing its own attributes