bootstrap pg_shseclabel in relcache initialization

From: Adam Brightwell <adam(dot)brightwell(at)crunchydata(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: bootstrap pg_shseclabel in relcache initialization
Date: 2015-11-09 04:40:02
Message-ID: CAE_9P=jQ=s7Yx+oyMbwUMUGu5hutZVe3PSDsvqf-P2UnPdLH3g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi All,

While working on an auth hook, I found that I was unable to access the
pg_shseclabel system table while processing the hook. I discovered
that the only tables that were bootstrapped and made available at this
stage of the the auth process were pg_database, pg_authid and
pg_auth_members. Unfortunately, this is problematic if you have
security labels that are associated with a role which are needed to
determine auth decisions/actions.

Given that the shared relations currently exposed can also have
security labels that can be used for auth purposes, I believe it makes
sense to make those available as well. I have attached a patch that
adds this functionality for review/discussion. If this functionality
makes sense I'll add it to the commitfest.

Thanks,
Adam

Attachment Content-Type Size
bootstrap-pg_shseclabel-relcache.patch text/x-diff 3.8 KB

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kouhei Kaigai 2015-11-09 04:40:10 Re: Foreign join pushdown vs EvalPlanQual
Previous Message Jeff Janes 2015-11-09 04:22:35 Re: Bitmap index scans use of filters on available columns