Re: Inconsistent permission enforcement for schemas

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Inconsistent permission enforcement for schemas
Дата
Msg-id 1846618.1659372591@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Inconsistent permission enforcement for schemas  (Marcin Barczyński <mba.ogolny@gmail.com>)
Список pgsql-general
=?UTF-8?Q?Marcin_Barczy=C5=84ski?= <mba.ogolny@gmail.com> writes:
> Why can a user access a table from a forbidden schema if the table is
> explicitly specified in the definition of a view in an allowed schema? And
> not if the table is accessed by a function used in the view.

(1) Whether a view can access a table is determined by the ownership of
the view, not of the user using the view.

(2) It might be nice if the view's permissions were inherited by functions
called by the view, but we've not made that happen.  You might be able to
approximate it by marking such functions SECURITY DEFINER; although that
makes the function's permissions those of the function's owner not the
view's owner.

            regards, tom lane



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

Предыдущее
От: Marcin Barczyński
Дата:
Сообщение: Inconsistent permission enforcement for schemas
Следующее
От: "sivapostgres@yahoo.com"
Дата:
Сообщение: Re: Creation of FK without enforcing constraint for existing data