Re: prevent users from SELECT-ing from pg_roles/pg_database - Mailing list pgsql-general

From Laurenz Albe
Subject Re: prevent users from SELECT-ing from pg_roles/pg_database
Date
Msg-id bd7905e2e1a920fb5ed3b8fa9ab0d7c8e8f2b52d.camel@cybertec.at
Whole thread Raw
In response to Re: prevent users from SELECT-ing from pg_roles/pg_database  (Andreas Joseph Krogh <andreas@visena.com>)
Responses Re: prevent users from SELECT-ing from pg_roles/pg_database
List pgsql-general
On Mon, 2024-05-27 at 09:33 +0200, Andreas Joseph Krogh wrote:
> I tried:
>
>   REVOKE SELECT ON pg_catalog.pg_database FROM public;
>
> But that doesn't prevent a normal user from querying pg_database it seems…

It works here.

Perhaps the "normal" user is a member of "pg_read_all_data".

Yours,
Laurenz Albe



pgsql-general by date:

Previous
From: Andreas Joseph Krogh
Date:
Subject: Re: prevent users from SELECT-ing from pg_roles/pg_database
Next
From: Laurenz Albe
Date:
Subject: Re: Long running query causing XID limit breach