Re: [GENERAL] restore error - language "plperlu" is not trusted

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Christopher Murtagh <christopher(dot)murtagh(at)mcgill(dot)ca>, pgsql-patches(at)postgresql(dot)org
Subject: Re: [GENERAL] restore error - language "plperlu" is not trusted
Date: 2003-12-18 20:28:51
Message-ID: 200312182128.51521.peter_e@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-patches

Attached is my proposed patch for this problem, to be put in 7.4.1.
Please someone give it a quick check.

Tom Lane wrote:
> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> > Tom Lane wrote:
> >> Uh, no, because you can say something like
> >> revoke all on language plperlu from public;
> >> and end up with non-null lanacl (because it instantiates the
> >> default assumption that the owner has all privileges).
> >
> > OK, that needs to be disallowed.
>
> Fair enough. I thought it was a bit odd to disallow GRANT but allow
> REVOKE anyway.
>
> >> We could possibly hack the backend to avoid that, but I think
> >> pg_dump will need the special-case test anyway since it has to be
> >> able to cope with existing databases, wherein lanacl may be
> >> non-null.
> >
> > So far we know of 1 such database. I'd like to see some more
> > before we bother about it.
>
> It's a one-line addition --- just put the dumpACL call inside
> "if (lanpltrusted)". I think it is a reasonable change. We'd have
> to do something anyway, because the existing pg_dump code is
> certainly broken for dumping untrusted languages from pre-7.3
> databases (it assumes a nonempty lanacl setting in that case).

Attachment Content-Type Size
untrusted-patch text/x-diff 2.9 KB

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2003-12-18 20:30:19 Re: functions returning sets
Previous Message Mark Twombley 2003-12-18 19:37:12 Has anyone seen an ADO Provider for Postresql?

Browse pgsql-patches by date

  From Date Subject
Next Message Tom Lane 2003-12-18 20:45:43 Re: [GENERAL] restore error - language "plperlu" is not trusted
Previous Message Andrew Dunstan 2003-12-18 20:17:26 Re: replace all with * in pg_hba.conf