Re: [HACKERS] Trigger and permissions

From: "Vadim B(dot) Mikheev" <vadim(at)sable(dot)krasnoyarsk(dot)su>
To: Jan Wieck <jwieck(at)debis(dot)com>
Cc: PostgreSQL HACKERS <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [HACKERS] Trigger and permissions
Date: 1998-02-06 01:54:19
Message-ID: 34DA6D4B.D251217F@sable.krasnoyarsk.su
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jan Wieck wrote:
>
> I think it would be nice to to have something like setuid
> triggers. Some triggers cause a change of the user and some
> don't. A setuid_user attribute in pg_trigger could do that
> job. If that doesn't contain NULL, the trigger will be
> invoked under the permissions of the user in that field.
> Obviously to say that a normal user can only create setuid
> triggers with his own name.
>
> Should the syntax for CREATE TRIGGER be extended here or
> should we have a completely different command for that?
>
> Any suggestions/comments?

First, what standard says about execution permissions of triggers,
functions and procedures ?

Second, if we would decide to have both setuid and non-setuid
triggers (etc) then I would suggest special command to set
setuid "bit" - just to don't change syntax of both CREATE TRIGGER
and CREATE FUNCTION. Also, in "normal" dbsystem, user first
does CREATE VIEW and only after that does GRANT ... TO ... (it likes
setting setuid bit on VIEW).

Vadim

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Thomas G. Lockhart 1998-02-06 02:28:07 Re: [HACKERS] Re: [QUESTIONS] impossible insert data into VARCHAR
Previous Message Julia Anne Case 1998-02-06 00:41:41 More info on Debug Info