Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fmiZd-0004rA-EE for pgsql-bugs@arkaria.postgresql.org; Mon, 06 Aug 2018 16:41:37 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1fmiZb-0003mx-04 for pgsql-bugs@arkaria.postgresql.org; Mon, 06 Aug 2018 16:41:35 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fmiZa-0003ma-QB for pgsql-bugs@lists.postgresql.org; Mon, 06 Aug 2018 16:41:34 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1fmiZX-00077t-Nr for pgsql-bugs@lists.postgresql.org; Mon, 06 Aug 2018 16:41:33 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id w76GfL0k022578; Mon, 6 Aug 2018 12:41:21 -0400 From: Tom Lane To: Dean Rasheed cc: Andres Freund , Amit Langote , Mario De Frutos Dieguez , pgsql-bugs@lists.postgresql.org Subject: Re: Fwd: Problem with a "complex" upsert In-reply-to: <22581.1533422229@sss.pgh.pa.us> References: <18795.1529600753@sss.pgh.pa.us> <8da3739d-da24-1125-cab6-b68d6ec1bc6a@lab.ntt.co.jp> <30415.1531256373@sss.pgh.pa.us> <4b956567-8283-1b8a-7cd7-f8b6e626bba9@lab.ntt.co.jp> <20180803184638.gdii7mja7qfc3fba@alap3.anarazel.de> <7664.1533335577@sss.pgh.pa.us> <20180803224455.4g2hnvciynu2s7iv@alap3.anarazel.de> <8968.1533337119@sss.pgh.pa.us> <22581.1533422229@sss.pgh.pa.us> Comments: In-reply-to Tom Lane message dated "Sat, 04 Aug 2018 18:37:09 -0400" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <22576.1533573681.1@sss.pgh.pa.us> Date: Mon, 06 Aug 2018 12:41:21 -0400 Message-ID: <22577.1533573681@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk I wrote: > Attached is our finished patch against HEAD. This is pretty much all > Dean's work, but I'm posting it on his behalf because it's late in the UK > and he's gone offline for the day. In the interests of getting a > full set of buildfarm testing on the patch before Monday's wrap deadline, > I'm going to finish up back-porting the patch and push it tonight. Final(?) note on this thread --- the security team realized over the weekend that this bug constitutes a security issue, because you can do more than crash the server. We don't normally consider simple crashes as being CVE-worthy problems, but in this case, there's potential for datatype confusion, which can be leveraged to allow disclosure of server memory (as we've seen in other bugs before). We also realized that it's possible to update a column you supposedly don't have privilege to update, as long as there's some other column you do. We've retroactively obtained a CVE number and will be describing this as a security problem in the release notes. regards, tom lane