From: | Sean Chittenden <sean-pgsql-general(at)chittenden(dot)org> |
---|---|
To: | tillea(at)rki(dot)de |
Cc: | PostgreSQL General <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Postgres permissions for www-data |
Date: | 2001-06-20 18:31:44 |
Message-ID: | 20010620113144.A73643@rand.tgd.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Check out the GRANT syntax, I bet you haven't granted SELECT
permissionso to the user/table combo. -sc
On Wed, Jun 20, 2001 at 01:23:26PM +0200, tillea(at)rki(dot)de wrote:
> Delivered-To: chittenden(dot)org-sean-pgsql-general(at)chittenden(dot)org
> From: tillea(at)rki(dot)de
> Date: Wed, 20 Jun 2001 13:23:26 +0200 (CEST)
> X-X-Sender: <tillea(at)wr-linux02(dot)rki(dot)ivbb(dot)bund(dot)de>
> To: PostgreSQL General <pgsql-general(at)postgresql(dot)org>
> Subject: [GENERAL] Postgres permissions for www-data
> Precedence: bulk
>
> Hello,
>
> I'm using Zope 2.3.2, PostgreSQL 7.1.2 and psycopg 0.99.2.
> On a Debian system Zope is running as user www-data.
>
> I created this user using
> > createuser www-data
>
> Moreover I made sure in psql:
>
> web=# select usename from pg_user;
> usename
> ----------
> postgres
> tillea
> www-data
> (3 rows)
> web=# grant all on testtable to "web-data" ;
> CHANGE
>
> which seems to be OK so far.
>
> Opening a database connection from Zope works well. I used the
> connection string:
>
> dbname=web
>
> Unfortunately if I want to test the connection using
>
> select * from testtable ;
>
> I get
>
> Error Type: ProgrammingError
> Error Value: ERROR: testtable: Permission denied. select * from testtable ;
>
>
> Looking at /var/log/postgres.log I see the following entries:
>
> 2001-06-19 14:05:24 [22300] DEBUG: connection: host=[local] user=www-data database=web
> 2001-06-19 14:05:43 [22300] ERROR: testtable: Permission denied.
>
> I also studied the archive:
>
> http://fts.postgresql.org/db/mw/msg.html?mid=53327
> http://fts.postgresql.org/db/mw/msg.html?mid=30785
>
> deal with this problem but I found no solution for this problem.
> According to this mails I tried to remap the username using pg_ident.conf
> but nothing helped (remapping doesn't seem to work because the log-entry
> did not change).
>
> Moreover if I try to use a connection string with any username (different
> from www-data or also www-data) and password even the connection itself
> fails.
>
> Kind regards
>
> Andreas.
>
>
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> message can get through to the mailing list cleanly
--
Sean Chittenden
From | Date | Subject | |
---|---|---|---|
Next Message | Thalis A. Kalfigopoulos | 2001-06-20 18:33:34 | Re: sum of row values.. |
Previous Message | Marc SCHAEFER | 2001-06-20 18:24:58 | Re: What do you do when...? A schema Question |