Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qkmZm-00GRre-Ug for pgsql-general@arkaria.postgresql.org; Mon, 25 Sep 2023 14:28:42 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1qkmZl-001wp9-5z for pgsql-general@arkaria.postgresql.org; Mon, 25 Sep 2023 14:28:41 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qkmZk-001wot-QE for pgsql-general@lists.postgresql.org; Mon, 25 Sep 2023 14:28:40 +0000 Received: from sss.pgh.pa.us ([68.162.161.243]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1qkmZi-006ZDA-37 for pgsql-general@lists.postgresql.org; Mon, 25 Sep 2023 14:28:39 +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 38PESYvl170506; Mon, 25 Sep 2023 10:28:34 -0400 From: Tom Lane To: Alexander Petrossian cc: Luca Ferrari , =?utf-8?B?0JDQu9C10LrRgdCw0L3QtNGAINCf0LXRgtGA0L7RgdGP0L0=?= , "pgsql-general@lists.postgresql.org" Subject: Re: debugger from superuser only.... why? In-reply-to: <086C5BA0-7B8F-42EE-ABEC-3EF403D1599B@gmail.com> References: <6006191695187640@mail.yandex.ru> <086C5BA0-7B8F-42EE-ABEC-3EF403D1599B@gmail.com> Comments: In-reply-to Alexander Petrossian message dated "Fri, 22 Sep 2023 14:28:22 +0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <170504.1695652114.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Mon, 25 Sep 2023 10:28:34 -0400 Message-ID: <170505.1695652114@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Alexander Petrossian writes: >>> I am wondering why is this, why not allow debugging for non-privileged= users? Seems obvious to me that it'd be a nasty security hole, ie you could take control of somebody else's session and make it do things you don't have permissions for. Even if there's a way to restrict debugging connections to sessions owned by the same user, you'd have a big problem with being able to change the behavior of security-definer functions. Clearly, the authors of pldebugger decided that was a can of worms they didn't care to open. regards, tom lane