pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ron <ronljohnsonjr@gmail.com>
To: pgsql-general@lists.postgresql.org
Subject: Re: Can the current session be notified and refreshed with a new credentials context?
Date: Mon, 22 Jun 2020 16:21:19 -0500
Message-ID: <1fc4b6d1-e81f-2f8e-b958-18c13ac144e2@gmail.com> (raw)
In-Reply-To: <CABtmK-iEp48fNwHTa3PzdQyFxmDgV3c6OhzNYiOHezfaoJbHzg@mail.gmail.com>
References: <CABtmK-iEp48fNwHTa3PzdQyFxmDgV3c6OhzNYiOHezfaoJbHzg@mail.gmail.com>

On 6/22/20 4:07 PM, AC Gomez wrote:
> Suppose you have the following scenario:
>
> 1: Call some function with a certain user and password
> 2: From inside that function, have several calls using DBLink
> 3: At some point during the running of that function a password rotation(a 
> separate process) comes along and updates the session user password and 
> the User Mappings with this new rotated password
> 4: Now there is a discrepancy between the password used when the session 
> started and the password in the User Mappings
> 5: The result is that on the next DBLink call the main function will fail 
> because the session is still running with the old password but we have 
> changed the User Mappings.
>
> We have proven this by separating out every DBLINK call as its own new 
> session and running password rotation in between dblink calls. Then things 
> will work.
>
> My question: Is there a way to update or refresh the session with the new 
> password that was rotated so that the main function keeps running 
> seamlessly through all it's DBLink calls?
>
> If something like this is not available, then password rotation can _only 
> run_ when nothing else is running.

I've not seen such a thing on *any* system.


-- 
Angular momentum makes the world go 'round.

view thread (9+ messages)  latest in thread

Message-ID: <1fc4b6d1-e81f-2f8e-b958-18c13ac144e2@gmail.com>
Permalink:  ../1fc4b6d1-e81f-2f8e-b958-18c13ac144e2@gmail.com/
Also on:    postgresql.org/message-id/1fc4b6d1-e81f-2f8e-b958-18c13ac144e2@gmail.com

 · 

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: ronljohnsonjr@gmail.com
  Subject: Re: Can the current session be notified and refreshed with a new credentials context?
  In-Reply-To: <1fc4b6d1-e81f-2f8e-b958-18c13ac144e2@gmail.com>
  References: <CABtmK-iEp48fNwHTa3PzdQyFxmDgV3c6OhzNYiOHezfaoJbHzg@mail.gmail.com> <1fc4b6d1-e81f-2f8e-b958-18c13ac144e2@gmail.com>

* 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