Re: Grantor name gets lost when grantor role dropped

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: Grantor name gets lost when grantor role dropped
Дата
Msg-id 20070417024430.GF10557@alvh.no-ip.org
обсуждение исходный текст
Ответ на Grantor name gets lost when grantor role dropped  (Jeff Davis <pgsql@j-davis.com>)
Ответы Re: Grantor name gets lost when grantor role dropped  (Russell Smith <mr-russ@pws.com.au>)
Список pgsql-bugs
Jeff Davis wrote:

> CREATE ROLE test_role
>   NOSUPERUSER INHERIT NOCREATEDB NOCREATEROLE;
>
> CREATE ROLE invalid_grantor
>   SUPERUSER INHERIT NOCREATEDB NOCREATEROLE;
>
> SET ROLE invalid_grantor;
> GRANT "postgres" TO "test_role";
> SET ROLE postgres;
>
> select * from pg_roles;
>
> select pg_auth_members.*, ur.rolname, gr.rolname from pg_auth_members LEFT JOIN pg_roles ur ON roleid = oid
> LEFT JOIN pg_roles gr ON gr.oid = grantor;
>
> DROP ROLE invalid_grantor;
>
> select pg_auth_members.*, ur.rolname, gr.rolname from pg_auth_members LEFT JOIN pg_roles ur ON roleid = oid
> LEFT JOIN pg_roles gr ON gr.oid = grantor;
>
> DROP ROLE test_role;

The problem here is that we allowed the drop of invalid_grantor.  We are
missing a shared dependency on it.

--
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.

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

Предыдущее
От: Jeff Davis
Дата:
Сообщение: Grantor name gets lost when grantor role dropped
Следующее
От: Russell Smith
Дата:
Сообщение: Re: Grantor name gets lost when grantor role dropped