pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Access control on the read replica
2+ messages / 1 participants
[nested] [flat]

* Access control on the read replica
@ 2020-04-21 12:43  Мазлов Владимир <vlmazlov@yandex.ru>
  0 siblings, 0 replies; 2+ messages in thread

From: Мазлов Владимир @ 2020-04-21 12:43 UTC (permalink / raw)
  To: pgsql-general

<div>Hi,</div><div> </div><div>What I've been trying to do: write a web app that, upon receiving a request, automatically gets a DB connection with <strong>only </strong>the permissions it needs.</div><div> </div><div>There are a number of solutions to this problem: you could use triggers/view, you could use security definer functions to grant/revoke permissions for a pool of roles. None of the solutions I've been able to come up with work on connections to the standby.</div><div> </div><div>Does anything I've stated above strike you as obviously wrong? If not, do you perhaps have any ideas on how this problem could be tackled?</div><div> </div><div>I would very much appreciate any ideas.</div><div> </div><div>Cheers,</div><div>Vladimir</div>





^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Access control on the read replica
@ 2020-04-21 12:47  Мазлов Владимир <vlmazlov@yandex.ru>
  0 siblings, 0 replies; 2+ messages in thread

From: Мазлов Владимир @ 2020-04-21 12:47 UTC (permalink / raw)
  To: pgsql-general

<div><div><div><div><div><div><div><div><div>Hi,</div><div> </div><div>What I've been trying to do: write a web app that, upon receiving a request, automatically gets a DB connection with only the permissions it needs. In order to do that I'd like to create a mechanism for dynamically granting a role a set of permissions necessary for the given request and then revoking them (alternatively, we could pre-create a number of roles for each set of permissions but I'd like to avoid that solution, as it's very incovenient).</div><div> </div><div>There are a number of solutions to this problem: you could use triggers/views, you could use security definer functions to grant/revoke permissions for a pool of roles. None of the solutions I've been able to come up with work on connections to the standby.</div><div> </div><div>Does anything I've stated above strike you as obviously wrong? If not, do you perhaps have any ideas on how this problem could be tackled?</div><div> </div><div>I would very much appreciate any ideas.</div><div> </div><div>Cheers,</div><div>Vladimir</div></div></div></div></div></div></div></div></div>

^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2020-04-21 12:47 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2020-04-21 12:43 Access control on the read replica Мазлов Владимир <vlmazlov@yandex.ru>
2020-04-21 12:47 Access control on the read replica Мазлов Владимир <vlmazlov@yandex.ru>

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