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 1rPERS-00A9Vu-Vq for pgsql-bugs@arkaria.postgresql.org; Mon, 15 Jan 2024 04:19:19 +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 1rPERO-00DSX3-Ao for pgsql-bugs@arkaria.postgresql.org; Mon, 15 Jan 2024 04:19:14 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPERO-00DSWv-2k for pgsql-bugs@lists.postgresql.org; Mon, 15 Jan 2024 04:19:14 +0000 Received: from wout3-smtp.messagingengine.com ([64.147.123.19]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPERL-001ri4-7C for pgsql-bugs@lists.postgresql.org; Mon, 15 Jan 2024 04:19:13 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailout.west.internal (Postfix) with ESMTP id D18403200A9E; Sun, 14 Jan 2024 23:19:07 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute7.internal (MEProxy); Sun, 14 Jan 2024 23:19:08 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:cc:content-type:content-type:date:date:from:from:in-reply-to :in-reply-to:message-id:mime-version:references:reply-to:subject :subject:to:to; s=fm2; t=1705292347; x=1705378747; bh=9EngydAz7Y v4/0wJmSzQhBgGJ49MhkrDKPV64DoPIKQ=; b=tbusbzg+LjwpPaB9w2/N0HmOUn LWIVEtefoXwBcEk3PeqEbzlylfqTdeS9kkxWQc/oR96pwSOl2WBV+VmGGfdCSzFY RoKQkJn5HY0MxhouGiHKqcbjsQcdwObvdiU6F+Tn2N3FyU8anYyVi0ucxX5mJbYP Gsa4PWcSAgPj9atacEq/aJTJs0S6ay2kk1NySfNUSNJ/tmf4HVTnkhOfVwBaIgdd k2PWk3V5YZfdIQmQPS1CxJKGG96wIDJ4RxwkDm2vPMB40mLdK3r8qW7XMuK4lJLT DbF3vyDEPOanK574gKW0lLr01F2ZJCP82jzxkrRJ4iEg8j8O4r+IPZg5/pCA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-type:content-type:date:date :feedback-id:feedback-id:from:from:in-reply-to:in-reply-to :message-id:mime-version:references:reply-to:subject:subject:to :to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; t=1705292347; x=1705378747; bh=9EngydAz7Yv4/0wJmSzQhBgGJ49M hkrDKPV64DoPIKQ=; b=r7eU7dj77Qi3d9BnwhNVDz6Dhp8yUejFXP7jsTJ1WY0R /zXwUTRp3f31BfYwvasI1ByHrJY33J17h9SUzE5siiYKms5EG9k0PXEUE4emnmD2 WomJP/CKJt/+rdvUNfbQGPra314+yAq2LTFYpthHtoDUmLhR0dw3L4ixhpxXr0K6 yWkv6Yt1cXwXw6ZBgkDyCrkWdOFe4pidaD5bu1c7FTr/oza/vD+mwiWaUhCB+Rfh Ic+si1gwf5KaQt1mut+f19DMiKku2FBpureJcO15RUa0p6z8Vm47ue4Wumapl5Qa zVgMRRx2RdjqICJgIdMfSI5hHtpk8td0l/jKzEZ5jQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvkedrvdejtddgieelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne gfrhhlucfvnfffucdljedtmdenucfjughrpeffhffvvefukfhfgggtuggjsehgtdorredt tddvnecuhfhrohhmpefoihgthhgrvghlucfrrghquhhivghruceomhhitghhrggvlhesph grqhhuihgvrhdrgiihiieqnecuggftrfgrthhtvghrnhepffduleehgefhkeefgfeftdfh kedutddvhfdukeeggeehieekffelhfelkeehteefnecuvehluhhsthgvrhfuihiivgeptd enucfrrghrrghmpehmrghilhhfrhhomhepmhhitghhrggvlhesphgrqhhuihgvrhdrgiih ii X-ME-Proxy: Feedback-ID: i0fe9450f:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Sun, 14 Jan 2024 23:19:05 -0500 (EST) Date: Mon, 15 Jan 2024 13:18:54 +0900 From: Michael Paquier To: Tom Lane Cc: Dmitry Koval , pgsql-bugs@lists.postgresql.org Subject: Re: BUG #18274: Error 'invalid XML content' Message-ID: References: <18274-98d16bc03520665f@postgresql.org> <1616257.1704651529@sss.pgh.pa.us> <5588db01-45be-48ff-b158-85f789bc502c@postgrespro.ru> <1314313.1705259848@sss.pgh.pa.us> <0eea123f-388a-41ea-9df3-d4606cf9ed8d@postgrespro.ru> <1369582.1705288593@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="wOFcet531KBT52nI" Content-Disposition: inline In-Reply-To: <1369582.1705288593@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --wOFcet531KBT52nI Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Sun, Jan 14, 2024 at 10:16:33PM -0500, Tom Lane wrote: > Blowing out a backend's memory or CPU consumption is not something > we try hard to prevent, so I'm not terribly worried on that score. > The one thing I'm concerned about is that raising these limits could > make bugs (like integer overflow problems) reachable that were not > otherwise, and that such bugs might rise to the level of security > problems. They've had such issues before (CVE-2022-40303) and it'd be > foolish to be sure that none remain. Still, that's clearly their bug > not our bug. Interesting. We could always keep our coding more defensive, not sure entirely how. I am not sure that this is enough to not just use the upper limit, though. Being able to manipulate larger XML elements sounds like a fair argument from the user perspective these days, especially with memory being cheaper and larger. 1fb2e0dfc631 has added the huge option back in 2009 in libxml2, so it's been around for some time. -- Michael --wOFcet531KBT52nI Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAmWksi4ACgkQnvQgOdby QH1NgQ//S/HtxJYyZSjZY8q7ouPImzFpscCjLuO3Ar/ubH/089kx+SfV7J4JWfFk t+0MKQXEW0Cs3/jEA+jNWybM/I/fmo0mu5+y5qEOxnUPaoQmIEiG9WSgUt77eLNM Zm/QjOvxEzJZR57GCyr03wKwTFhnOr12N5wS25uuinmrz+0EW/M4X8v+irPIY8/r WS6AxfJtOvG+jxvYfnD6pddV7ANonOTqT1lh8AMDwwX3p3T6zEE4aGDa+f9XDDL5 tSrHCOnfElY5AxxybbGYkdCzMVdomNIfBavnMatLGmBkLo4pdjRf5xlEEFpMWlvM yfZawhno25vHCkNW0GrWBnPTgougv1n3jmjAG8CcB2sAwASVlbiQY27oz25KWb7V wlkfq1oi3KkElXBEmTaVuETKXTR23Qs0FyKMD3j2CvYury92uu0EdDmsHwIfFxhb QFX4Bx7tEg2p6dnHKj+1xMCFXd4qV9cD5QfWOWd9M55YTFF8/lTLhrwvWYUJp+Ek abmjifbr9i11QaMWRiw6D3L/duGZFUsUBdJ9nPeHljdYs0ZLjP7jyshtRhPUDJRD mDRq8sm/DFSo9uf6xH8xxsWbQjwhuk4Xhn4AVwSsoe8S5vcYiMSOpRFSYhc7y3cE Wuwpmd1FrNc3BME7j1AOYeUyaMwzZRmIyl6fw3guRMqEwSaVlV8= =N9O5 -----END PGP SIGNATURE----- --wOFcet531KBT52nI--