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 1pr90k-00006W-Qc for pgsql-general@arkaria.postgresql.org; Tue, 25 Apr 2023 03:06:34 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1pr90j-0007Qn-NH for pgsql-general@arkaria.postgresql.org; Tue, 25 Apr 2023 03:06:33 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pr90j-0007Qd-CQ for pgsql-general@lists.postgresql.org; Tue, 25 Apr 2023 03:06:33 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1pr90g-001jrT-9O for pgsql-general@lists.postgresql.org; Tue, 25 Apr 2023 03:06:32 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 33P36SMb603517; Mon, 24 Apr 2023 23:06:28 -0400 From: Tom Lane To: jian he cc: pgsql-general list Subject: =?UTF-8?Q?Re:_wiki.postgres_=E2=80=8B_Tighten_trigger_permission_?= =?UTF-8?Q?checks_already_resolved?= In-reply-to: References: Comments: In-reply-to jian he message dated "Tue, 25 Apr 2023 10:09:43 +0800" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <603515.1682391988.1@sss.pgh.pa.us> Date: Mon, 24 Apr 2023 23:06:28 -0400 Message-ID: <603516.1682391988@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk jian he writes: > The following Todo item seems already resolved in pg15. > https://wiki.postgresql.org/wiki/Todo#Triggers >> Tighten trigger permission checks >> - Security leak with trigger functions? >> > But it seems to not appear in the pg15 release notes. (I searched for the > keywords "trigger" and "function"). The case shown at the head of that thread was fixed more than a decade ago, cf commit 891e6e7bf (CVE-2012-0866). However, the followup questions discussed in the thread are still live: should there be a run-time not only trigger-creation-time privilege check, and if so what should it check exactly? And is a separate TRIGGER privilege even reasonable, rather than just saying you must be table owner to create a trigger? regards, tom lane