pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Preventing database access (including valid users in other databases)
2+ messages / 2 participants
[nested] [flat]

* Preventing database access (including valid users in other databases)
@ 2005-09-26 10:09  Allan Kamau <kamauallan@yahoo.com>
  0 siblings, 1 reply; 2+ messages in thread

From: Allan Kamau @ 2005-09-26 10:09 UTC (permalink / raw)
  To: pgsql-admin

I would like to prevent users including users who may
be valid in other databases from accessing a
particular database, I have excluded database –
username associations of their usernames with the
database in the hba.conf file, but I observed that
they can still connect to the database, query metadata
(by use of \d) but cannot perform queries. Is there a
way to fully prevent database connect and query of
metadata?

Interesting scenario, I have a user who owns database
objects (tables, sequences) in a database, now I have
decided not to allow the user by connect to the
database by excluding the user's username from the
database – username association in the hba.conf, I
restarted the server. However the user can still
connect to the database, and the user can query the
objects they own but cannot query objects they do not
own in that database. Is this the expected behaviour
and should I explicitly change ownership of the
objects.

Allan.



		
__________________________________ 
Yahoo! Mail - PC Magazine Editors' Choice 2005 
http://mail.yahoo.com



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Preventing database access (including valid users in
@ 2005-09-27 14:57  Robert Treat <xzilla@users.sourceforge.net>
  parent: Allan Kamau <kamauallan@yahoo.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Robert Treat @ 2005-09-27 14:57 UTC (permalink / raw)
  To: Allan Kamau <kamauallan@yahoo.com>; +Cc: pgsql-admin

On Mon, 2005-09-26 at 06:09, Allan Kamau wrote:
> Interesting scenario, I have a user who owns database
> objects (tables, sequences) in a database, now I have
> decided not to allow the user by connect to the
> database by excluding the user's username from the
> database – username association in the hba.conf, I
> restarted the server. However the user can still
> connect to the database, and the user can query the
> objects they own but cannot query objects they do not
> own in that database. Is this the expected behaviour

Personally I think you've misconfigured your pg_hba.conf. If you'd like
to send it along with your db version you might be able to get a more
definitive answer.

> and should I explicitly change ownership of the
> objects.
> 

Well, it doesn't make much sense to me to have a bunch of objects in a
database owned by someone who will never be allowed to connect to that
database. 


Robert Treat
-- 
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2005-09-27 14:57 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-09-26 10:09 Preventing database access (including valid users in other databases) Allan Kamau <kamauallan@yahoo.com>
2005-09-27 14:57 ` Re: Preventing database access (including valid users in Robert Treat <xzilla@users.sourceforge.net>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox