Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1knpaq-0003Us-S1 for pgsql-admin@arkaria.postgresql.org; Fri, 11 Dec 2020 21:04:48 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1knpap-0005sa-Os for pgsql-admin@arkaria.postgresql.org; Fri, 11 Dec 2020 21:04:47 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1knpap-0005sS-HU for pgsql-admin@lists.postgresql.org; Fri, 11 Dec 2020 21:04:47 +0000 Received: from mailout.easymail.ca ([64.68.200.34]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1knpan-0001zc-4a for pgsql-admin@lists.postgresql.org; Fri, 11 Dec 2020 21:04:47 +0000 Received: from localhost (localhost [127.0.0.1]) by mailout.easymail.ca (Postfix) with ESMTP id 12703A2707; Fri, 11 Dec 2020 21:04:42 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at emo05-pco.easydns.vpn Received: from mailout.easymail.ca ([127.0.0.1]) by localhost (emo05-pco.easydns.vpn [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id M8eYSw76pR-g; Fri, 11 Dec 2020 21:04:41 +0000 (UTC) Received: from shr-macbook-pro.local (unknown [4.28.96.150]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mailout.easymail.ca (Postfix) with ESMTPSA id 61337A26FE; Fri, 11 Dec 2020 21:04:35 +0000 (UTC) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 13.4 \(3608.120.23.2.4\)) Subject: Re: 12 to 13 migration, the privs error with pg_pltemplate From: Scott Ribe In-Reply-To: <20201211203634.GB16415@tamriel.snowman.net> Date: Fri, 11 Dec 2020 14:04:34 -0700 Cc: Tom Lane , Pgsql-admin Content-Transfer-Encoding: quoted-printable Message-Id: References: <20201211203634.GB16415@tamriel.snowman.net> To: Stephen Frost X-Mailer: Apple Mail (2.3608.120.23.2.4) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk > On Dec 11, 2020, at 1:36 PM, Stephen Frost wrote: >=20 > Yes, I specifically asked if you were looking at the correct database > previously, because it matters: At that time I thought I had run the original REVOKE command in the = target database, and then tried ALTER DEFAULT PRIVILEGES in postgres. I = was probably mistaken. > I'm pretty sure none of this has anything to do with DEFAULT = PRIVILEGES > as those only actually apply when a new table is created (and not from = a > template database), and that's just never the case with any PG catalog > tables. So the fact that default privs were set on the system catalogs was = inappropriate, but harmless in this case? > What might be useful to point out is that only a superuser can change > the privileges associated with PG catalog tables and that you really > should be careful who you grant superuser privileges to. Yes, that's one thing I took care of earlier this year: change our = processes such that we were able to remove superuser from the = commonly-used service accounts.=