Re: "has_column_privilege()" issue with attnums and non-existent columns

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Joe Conway <mail(at)joeconway(dot)com>
Cc: Chengxi Sun <sunchengxi(at)highgo(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Ian Barwick <barwick(at)gmail(dot)com>, David Steele <david(at)pgmasters(dot)net>
Subject: Re: "has_column_privilege()" issue with attnums and non-existent columns
Date: 2021-03-30 22:22:45
Message-ID: 2994045.1617142965@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Joe Conway <mail(at)joeconway(dot)com> writes:
> Heh, I missed the forest for the trees it seems.
> That version undid the changes fixing what Ian was originally complaining about.

Duh, right. It would be a good idea for there to be a code comment
explaining this, because it's *far* from obvious. Say like

* Check for column-level privileges first. This serves in
* part as a check on whether the column even exists, so we
* need to do it before checking table-level privilege.

My gripe about providing API-spec comments for the new aclchk.c
entry points still stands. Other than that, I think it's good
to go.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2021-03-30 22:38:59 Re: Trouble with initdb trying to run regression tests
Previous Message Alvaro Herrera 2021-03-30 22:22:01 Re: multi-install PostgresNode fails with older postgres versions