Re: Restricting user to see schema structure

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bryn Llewellyn <bryn(at)yugabyte(dot)com>
Cc: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>, Neeraj M R <neerajmr12219(at)gmail(dot)com>, pgsql-general list <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Restricting user to see schema structure
Date: 2022-05-13 03:08:06
Message-ID: 569304.1652411286@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Bryn Llewellyn <bryn(at)yugabyte(dot)com> writes:
> Maybe this entire discussion is moot when hackers can read the C code of PG's implementation…

Hmm ... in one way that's unrelated, but in another way perhaps it is.
Postgres' system catalogs have always been user-readable as much as
possible, excepting only cases that clearly might contain private data
such as pg_statistic or pg_user_mapping.umoptions. We have pretty much
no interest in revisiting that design choice, even if doing so wouldn't
likely break a couple decades' worth of client-side software development.
It's not very hard to draw a line connecting that design choice to our
open-source ethos.

Anyway, if you feel a need to prevent user A from seeing the catalog
entries for user B's database objects, the only answer we have is to
put A and B into separate databases. If despite that you want A and
B to be able to share some data, you can probably build the connections
you need using foreign tables or logical replication; but there's not
a lot of pre-fab infrastructure for that, AFAIK.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Bryn Llewellyn 2022-05-13 03:42:05 Re: Restricting user to see schema structure
Previous Message David G. Johnston 2022-05-13 03:01:35 Re: Restricting user to see schema structure