pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: chris <chrisk@pgsqlrocket.com>
To: pgsql-admin@lists.postgresql.org <pgsql-admin@lists.postgresql.org>
Subject: audit table with permissions
Date: Wed, 28 Feb 2018 14:12:34 -0700
Message-ID: <fa4dc973-83be-db37-44c3-d197c3908fbb@pgsqlrocket.com> (raw)

I created functions and a trigger to audit tables on my database but I 
have a problem with permissions on the functions and function schema I 
created. I can grant permissions to the current user of the original 
table being audited but I need a way to automate grants and revokes made 
to the original table so that any time those change in the future I 
don't have to worry about updating permissions or leaving a hole in 
security by granting all users full permissions to the functions and 
function schema.

 From my understanding event triggers can't be set the grant/revoke only 
create, alter or drop.

Any input would really help me, I'm very fresh to writing functions and 
triggers.

Thanks,

Chris





view thread (2+ messages)  latest in thread

Message-ID: <fa4dc973-83be-db37-44c3-d197c3908fbb@pgsqlrocket.com>
Permalink:  ../fa4dc973-83be-db37-44c3-d197c3908fbb@pgsqlrocket.com/
Also on:    postgresql.org/message-id/fa4dc973-83be-db37-44c3-d197c3908fbb@pgsqlrocket.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 using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: chrisk@pgsqlrocket.com, pgsql-admin@lists.postgresql.org
  Subject: Re: audit table with permissions
  In-Reply-To: <fa4dc973-83be-db37-44c3-d197c3908fbb@pgsqlrocket.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