PLPGSQL 'SET SESSION ROLE' problems ..

From: "Greg Wickham" <Greg(dot)Wickham(at)aarnet(dot)edu(dot)au>
To: <pgsql-general(at)postgresql(dot)org>
Subject: PLPGSQL 'SET SESSION ROLE' problems ..
Date: 2007-10-10 06:22:13
Message-ID: 964C943783CDCE4BBA0CE327AA8E7BA5C2802D@vm-a-ex1.ms.aarnet.edu.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general


Hi,

Is it possible to change the current role to another arbitrary role
using a PLPGSQL function?

In essence I've a function "authorise" created by the db superuser with
'SECURITY DEFINER' specificied.

However from within plpgsql the 'superuser' attribute isn't honored when
trying to change roles (ie: the non 'superuser' rules for role change
must be honoured).

Is this a bug?

tnx,

-greg

--

Browse pgsql-general by date

  From Date Subject
Next Message Albe Laurenz 2007-10-10 07:11:14 Re: replacing single quotes
Previous Message Hiroshi Saito 2007-10-10 05:42:57 Re: about Command Prompt.