Re: Is this a bug, possible security hole, or wrong

From: Mike Mascari <mascarm(at)mascari(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Sander Steffann <sander(at)steffann(dot)nl>, pgsql-general(at)postgresql(dot)org
Subject: Re: Is this a bug, possible security hole, or wrong
Date: 2002-06-13 11:45:37
Message-ID: 3D0885E1.8F369ACA@mascari.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Tom Lane wrote:
>
> "Sander Steffann" <sander(at)steffann(dot)nl> writes:
> > But he is right in that his trick works. This proves that views can not be
> > safely used for security, which is an important thing to realise...
>
> A different way to look at it is that the privilege of creating
> functions shouldn't be handed out willy-nilly. The trick of hiding
> recording operations in a function can be used in other ways besides
> this one.

Tom,

If a user has permissions to write PL/SQL functions, and the statistics
collector is running with STATS_COMMAND_STRING = true, could not that
user "log" other users' queries using the same technique I described by
querying pg_stat_activity? If so, isn't the labeling of PL/SQL (or
PL/Tcl, PL/Perl, etc.) as 'TRUSTED' an overstatement? ;-)

Mike Mascari
mascarm(at)mascari(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2002-06-13 13:06:18 Re: Help required with installing postgreSQL on SCO Openserver
Previous Message Stephane Bortzmeyer 2002-06-13 09:49:37 Setting up the pgReplicator: nightmare in the dark