Re: Remove default privilege from DB

From: Durumdara <durumdara(at)gmail(dot)com>
To: Charles Clavadetscher <clavadetscher(at)swisspug(dot)org>
Cc: Postgres General <pgsql-general(at)postgresql(dot)org>
Subject: Re: Remove default privilege from DB
Date: 2018-02-15 11:40:43
Message-ID: CAEcMXhm5sb-cw1Yek2T7dGnWJRP8-6Vr7kreQAC1Q-CY8VY=pw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Dear Charles!

2018-02-12 10:03 GMT+01:00 Charles Clavadetscher <clavadetscher(at)swisspug(dot)org
>:

> Hi
>
>
>
> *From:* Durumdara [mailto:durumdara(at)gmail(dot)com]
> *Sent:* Montag, 12. Februar 2018 09:32
> *To:* Postgres General <pgsql-general(at)postgresql(dot)org>
> *Subject:* Remove default privilege from DB
>
>
>
> Hello!
>
>
>
> I need to remove default privileges from a Database.
>
> After that some of them remains.
>
>
>
> Default access privileges
>
> Owner | Schema | Type | Access privileges
>
> ------------+--------+----------+-------------------
>
> postgres | | function | =X/postgres
>
> postgres | | sequence |
>
> postgres | | table |
>
> postgres | | type | =U/postgres
>
> *suser | | function | =X/suser*
>
> * suser | | sequence |*
>
> * suser | | table |*
>
> * suser | | type | =U/suser*
>
>
>
> How to completely remove the last items?
>
> Could you send me one example?
>
>
>
> I assume
>
>
>
> ALTER DEFAULT PRIVILEGES FOR ROLE suser REVOKE EXECUTE ON FUNCTIONS FROM
> PUBLIC;
>
> ALTER DEFAULT PRIVILEGES FOR ROLE suser REVOKE USAGE ON TYPE FROM PUBLIC;
>
>
>
> Bye
>
> Charles
>

After that:

Default access privileges
Owner | Schema | Type | Access privileges
------------+--------+----------+-------------------
suser | | function |
suser | | sequence |
suser | | table |
suser | | type |
(4 rows)

What are they?

select * from pg_default_acl

24629;0;"r";"{}"
24629;0;"S";"{}"
24629;0;"f";"{}"
24629;0;"T";"{}"

24629 = suser | namespace 0 = none in document
Hmmm... It's very strange for me. I don't find any point which links this
user to this database.

Do you have any idea?

Thanks
dd

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Charles Clavadetscher 2018-02-15 13:19:27 RE: Remove default privilege from DB
Previous Message pavan95 2018-02-15 11:09:50 Re: Upgrading from Postgresql 9.1 to 10