pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Murillo corvino rocha <murillo_corvinorocha@hotmail.com>
Cc: Adrian Klaver <adrian.klaver@aklaver.com>
Cc: pgsql-general@lists.postgresql.org <pgsql-general@lists.postgresql.org>
Subject: Re: RES: session_user different from current_user after normal login
Date: Fri, 18 Nov 2022 09:31:47 -0500
Message-ID: <2184327.1668781907@sss.pgh.pa.us> (raw)
In-Reply-To: <CO6PR17MB5028A71BE4007805FB33C8C3EB069@CO6PR17MB5028.namprd17.prod.outlook.com>
References: <CO6PR17MB50288F5AC97DF80B8EAB6B67EB069@CO6PR17MB5028.namprd17.prod.outlook.com>
	<359ae842-c217-1055-e24b-173918c1e5f3@aklaver.com>
	<CO6PR17MB5028A71BE4007805FB33C8C3EB069@CO6PR17MB5028.namprd17.prod.outlook.com>

Murillo corvino rocha <murillo_corvinorocha@hotmail.com> writes:
> I am just logging in (using psql) and doing the select: SELECT session_user, current_user;
> The PostgreSQL is an AWS RDS 12.12 instance. No script is being executed. No one besides me is connected to the database. Could it be any server level configuration? I’m pretty sure that few configurations were made to this database.

I believe it's possible to do ALTER USER ... SET ROLE ... or
ALTER DATABASE ... SET ROLE ..., which'd produce this sort of
effect.  psql's "\drds" metacommand would help remind you of
any such settings.  I can't offhand think of any other server-side
configuration that would do it.

			regards, tom lane





view thread (4+ messages)

Message-ID: <2184327.1668781907@sss.pgh.pa.us>
Permalink:  ../2184327.1668781907@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2184327.1668781907@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: tgl@sss.pgh.pa.us, murillo_corvinorocha@hotmail.com, adrian.klaver@aklaver.com
  Subject: Re: session_user different from current_user after normal login
  In-Reply-To: <2184327.1668781907@sss.pgh.pa.us>
  References: <CO6PR17MB50288F5AC97DF80B8EAB6B67EB069@CO6PR17MB5028.namprd17.prod.outlook.com> <359ae842-c217-1055-e24b-173918c1e5f3@aklaver.com> <CO6PR17MB5028A71BE4007805FB33C8C3EB069@CO6PR17MB5028.namprd17.prod.outlook.com> <2184327.1668781907@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox