Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 9D95A1337B85 for ; Tue, 23 Nov 2010 08:41:56 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 50360-04 for ; Tue, 23 Nov 2010 12:41:50 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from kuber.nabble.com (kuber.nabble.com [216.139.236.158]) by mail.postgresql.org (Postfix) with ESMTP id 17FBC1337B7A for ; Tue, 23 Nov 2010 08:41:49 -0400 (AST) Received: from sam.nabble.com ([192.168.236.26]) by kuber.nabble.com with esmtp (Exim 4.63) (envelope-from ) id 1PKrv7-0000L4-Jk for pgsql-admin@postgresql.org; Tue, 23 Nov 2010 04:24:25 -0800 Date: Tue, 23 Nov 2010 04:24:25 -0800 (PST) From: tomislavb To: pgsql-admin@postgresql.org Message-ID: <1290515065600-3276689.post@n5.nabble.com> Subject: managing access to database MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-0.777 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RFC_ABUSE_POST=0.001, URI_HEX=1.122 X-Spam-Level: X-Archive-Number: 201011/219 X-Sequence-Number: 36185 Hi to all, i've seen this is a popular topic but haven't found any concrete answers so far. So my scenario is this : - created a new user with : sudo -u postgres createuser -D -A -P john - created a new database with : sudo -u postgres createdb -E 'UTF8' -O john test - added plpgsql sudo -u postgres createlang plpgsql test After that i wanted to allow "external" access to the "test" database.=20 So i tried configuring the pg_hba.conf file. In my first attempt i added this line to pg_hba.conf: host =C2=A0 =C2=A0all =C2=A0 =C2=A0 john 0.0.0.0/0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 md5 And john had connect access to access to all databases and admin access to his "test" database. After that i wanted give john admin access to his "test" db, and absolutely no access to other databases. host test john 0.0.0.0/0 md5 It doesnt work. Can't login through pg_admin. I've played with revoking access to other databases, but to no avail. I'm quite positive i'm not the first one with this issue. There is a similar=20 http://postgresql.1045698.n5.nabble.com/Extended-security-restriction-to-an= y-role-with-login-access-td2089118.html#a2089128 thread on the matter.. Any help would be very appreciated. --=20 View this message in context: http://postgresql.1045698.n5.nabble.com/manag= ing-access-to-database-tp3276689p3276689.html Sent from the PostgreSQL - admin mailing list archive at Nabble.com.