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 1sJVDa-005F8L-SB for pgsql-bugs@arkaria.postgresql.org; Tue, 18 Jun 2024 09:33:34 +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 1sJVDY-00AWvF-8T for pgsql-bugs@arkaria.postgresql.org; Tue, 18 Jun 2024 09:33:33 +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 1sJVDX-00AWv7-LN for pgsql-bugs@lists.postgresql.org; Tue, 18 Jun 2024 09:33:32 +0000 Received: from fout7-smtp.messagingengine.com ([103.168.172.150]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sJVDV-001tHo-OH for pgsql-bugs@lists.postgresql.org; Tue, 18 Jun 2024 09:33:31 +0000 Received: from compute6.internal (compute6.nyi.internal [10.202.2.47]) by mailfout.nyi.internal (Postfix) with ESMTP id 132221380262; Tue, 18 Jun 2024 05:33:28 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute6.internal (MEProxy); Tue, 18 Jun 2024 05:33:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm2; t=1718703208; x= 1718789608; bh=WUifE9zdWsf94cj5DmE77+TBGn74LKLVM1NNKhElO+I=; b=G bmaPA17EsEBETDWBAkj6ofQqA8HeJaXIEZUP68yIAeEq6lWlskew5i37xM6PgYMf FfPGPuisRyLbqZGYgesKgK/KPZjxsZanuKPXJ/EzKuMEiv1gKFQemKtWI8Eo8Qwq OGzHS2mKy2xOFy0XngG3i9BCDIaIy+dmU9mL480ZoI7sXDgzxA5AFg64rX9uqoiK o6lUNQfqm6kzpo2rL6nUMkxD9GlDcOGwO4ldlvEZHeW5vIqDa9NGg719S4GEwpoa heGizyav77bOtTzj3KEOaYHDicbLmE4dW/++zGy419ylX4B4oi8WwJ+rOeiRccHe +xz4h3iEWqC9UQNi6e8Zw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrfedvjedgudehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkgggtugfgjgesthekredttddtjeenucfhrhhomheptehlvhgr rhhoucfjvghrrhgvrhgruceorghlvhhhvghrrhgvsegrlhhvhhdrnhhoqdhiphdrohhrgh eqnecuggftrfgrthhtvghrnhepvdektdffudfftdffffehfffhjeejhffgieeuueekjeek fffgudffhfduffffueevnecuffhomhgrihhnpegvnhhtvghrphhrihhsvggusgdrtghomh enucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrlhhv hhgvrhhrvgesrghlvhhhrdhnohdqihhprdhorhhg X-ME-Proxy: Feedback-ID: ia2694551:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 18 Jun 2024 05:33:27 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alvh.no-ip.org; s=schmee; t=1718703205; bh=mH6Bje/qZ1CGEhiZL2r6MuvsqAp7BHRbpiwq/u4Hdvs=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=aVBcFx+Lpa3WUX+q5HtGrQxxrm5EMKxQI44rej3uTd+4FRedlSW8+tsEAYrzCAXHS 9n4SkKB+JLeROSq490Dh7ldtsXaXieN95GN2PuJWWvEExatP+xJk3hOZ3Ad/iif9IZ 6G0iX8GDDnu6glDazhtFKXvn2UJIKrmOc/rMG2LHCemBtRBtqNZcfyc2llG4xbgUFi 8d7jahd8KnyrqxMV7/1KsOVUhmOiuxuAUWx9LM3m5FDVV0AwNPH7gqJkeu46S/wOBm 2yEeYhAP8lbK/TFJK8J7K5HoQ+1CNwXxs8n6Gne+6Pg/cpgcheTlj6gHY07m2BgQY4 +1K1eOrMex7Dw== Received: by schmee.alvh.no-ip.org (Postfix, from userid 1000) id 7A8D1527; Tue, 18 Jun 2024 02:33:25 -0700 (PDT) Date: Tue, 18 Jun 2024 11:33:25 +0200 From: Alvaro Herrera To: "David G. Johnston" Cc: voronaam@gmail.com, pgsql-bugs@lists.postgresql.org Subject: Re: BUG #18510: jsonpath does not support trailing backslash at the end of the query Message-ID: <202406180933.az7sf7jc74ny@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2024-Jun-14, David G. Johnston wrote: > It is working just fine. It sees both the regex and the backslash > character and then helpfully tells you that the regex you wrote is > bogus since the backslash you wrote isn't escaping anything. Not really connected to this bug, but I think we should get rid of the error that says that the end backslashes are useless. If that error wasn't there, we would be one step closer to being able to mark the operator for LIKE as leakproof. Right now, if you mark that operator as leakproof and use it in a security barrier view, attackers can leak entire strings by testing with that operator for each character one at a time. =# select * from secret where data like substring(data, 1, 7) escape 'r'; ERROR: LIKE pattern must not end with escape character Here I verify that the character number 7 is an 'r'. So this one error is the sole reason we have to mark the LIKE operator as leaky, which is sad. -- Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/ "Just treat us the way you want to be treated + some extra allowance for ignorance." (Michael Brusser)