postgresql - How to prevent a user from being able to see other databases and the tables from other databases? -


I want to create a postgradge user who can access only one database on the postgres server.

Currently my flow is:

  create database database 1; Create user user 1 with password 'pass'; Provide all privilege on database database 1 for user;  

But user1 can still see a list of DBS, users, tables etc. Is there any way to stop that user from seeing that information? The user needs to be able to write and read from that DB.

Thank you very much.

Each user can see other databases and roles listed, but never see tables in other databases Should not be able to.

If you have canceled all privileged privileges on a database except allocated, then the user will not be able to access the content of other databases.

Roles and databases are global, and are not easily blockable You can try the Frank Hyacons suggestion of selective iterations on system tables, but you take risks to do so. Postgresqual developers on Usenet mailing lists have tampered with access to the system catalog.

Between other devices, SQL assumes that they will be available without any available and poor performance.

Why is it too bad to know names of other databases and roles?


Comments

Popular posts from this blog

c# - sqlDecimal to decimal clr stored procedure Unable to cast object of type 'System.Data.SqlTypes.SqlDecimal' to type 'System.IConvertible' -

Calling GetGUIThreadInfo from Outlook VBA -

Obfuscating Python code? -