Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gylKe-0008Tv-7d for pgsql-general@arkaria.postgresql.org; Tue, 26 Feb 2019 22:36:13 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gylKc-0000f1-S5 for pgsql-general@arkaria.postgresql.org; Tue, 26 Feb 2019 22:36:10 +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_SHA1:256) (Exim 4.89) (envelope-from ) id 1gylKb-0000eu-8R for pgsql-general@lists.postgresql.org; Tue, 26 Feb 2019 22:36:10 +0000 Received: from [64.147.123.25] (helo=wout2-smtp.messagingengine.com) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gylKV-0005lp-QQ for pgsql-general@lists.postgresql.org; Tue, 26 Feb 2019 22:36:08 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.west.internal (Postfix) with ESMTP id 39C7B1746; Tue, 26 Feb 2019 17:35:41 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Tue, 26 Feb 2019 17:35:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm1; bh=/Inc2J2mcExTFYW8GLU7hFUj5sa 0XfMpxPPo+brS+vs=; b=Xm+C003X3Ix5GypmV7DakG9cIlsQ2xJZwhRZ0p+ZYOl e3UIZ1RGBlOwnX+k4uEoyRpFanvbxGYJ8nbOTpbnqBlRnj/Bo+d32LyvBU5l4W71 4ZzEi7vMiKBvoeoXBLGm2IcPibCGcTH6L1awr8djAfLD7YZol4GbKbXtPTgp9aQO ALkm90nJ/pKQdGVtlyjK1DLqkLK1K5OXQXIEqUZjnCPqDn/7WJR5iEGVF2G4pKke oUrfAbZLIJo3H2FeN5EFhyN77+1ofgwnxQqBRjMlw5qjajjzkFYgAlkEIKfmghYQ 8N4kXJ55eutA47RvB4XRTJQIreL7aOfzuz2tlFATThA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=/Inc2J 2mcExTFYW8GLU7hFUj5sa0XfMpxPPo+brS+vs=; b=rWsytUyRs9qirYK4nWa1KS zqeeGfZj9O4NaYgU9QIxxe1r+ALZAHs++hZFgHOP0iwKlsAM61Pqw6PLhmpo1388 iaanmkTPVrauPALzfwaMAr+bB+Bh8BeS69rb6q/Y0bt5IEauDuaJeYW+WoudFJfl gNbAtMUUqyKaR/t/mh+YkuxgyYbji9WoyAf3xCCEkV2YkQq0WQDInFKXrdwW6amS oXPkkuXja4Ubt49zssOX0IvddeJYb5LltGzfeF0xvZC10OGw8NqZ+dpwcl6Kr9Km /jrdd6uHqEV23tPrJr+a/bGP+yfNiFcP6O9xBxS1R4oVjDmLRDUdDImcqAfx9N+g == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedutddrudelgdduieejucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne gfrhhlucfvnfffucdlfeehmdenucfjughrpeffhffvuffkfhggtggujgesghdtreertddt vdenucfhrhhomhepofhitghhrggvlhcurfgrqhhuihgvrhcuoehmihgthhgrvghlsehprg hquhhivghrrdighiiiqeenucfkphepiedurddvudehrddufeejrdduiedvnecurfgrrhgr mhepmhgrihhlfhhrohhmpehmihgthhgrvghlsehprghquhhivghrrdighiiinecuvehluh hsthgvrhfuihiivgeptd X-ME-Proxy: Received: from paquier.xyz (c137162.net61215.cablenet.ne.jp [61.215.137.162]) by mail.messagingengine.com (Postfix) with ESMTPA id E99BDE4240; Tue, 26 Feb 2019 17:35:36 -0500 (EST) Date: Wed, 27 Feb 2019 07:35:28 +0900 From: Michael Paquier To: Tom Lane Cc: Peter Eisentraut , Hugh Ranalli , Bruce Momjian , pgsql-general@lists.postgresql.org Subject: Re: Channel binding not supported using scram-sha-256 passwords Message-ID: <20190226223528.GA1655@paquier.xyz> References: <20190215211417.GC14824@momjian.us> <20190218010614.GE1864@paquier.xyz> <56d28a96-6a18-8eb0-3c23-2a980a29a01f@2ndquadrant.com> <20190221044758.GK15532@paquier.xyz> <134517f0-2736-37ed-02c0-da3d41c7a0db@2ndquadrant.com> <20190222052809.GE24416@paquier.xyz> <4b0c2616-967e-356e-fff8-99f4177ff08f@2ndquadrant.com> <7017.1551193475@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="SLDf9lqlvOQaIe6s" Content-Disposition: inline In-Reply-To: <7017.1551193475@sss.pgh.pa.us> X-Host-Lookup-Failed: Reverse DNS lookup failed for 64.147.123.25 (deferred) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --SLDf9lqlvOQaIe6s Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Feb 26, 2019 at 10:04:35AM -0500, Tom Lane wrote: > Peter Eisentraut writes: >> I tried reproducing the issue locally, but the required OpenSSL version >> is too old to be easily available. >=20 > Hm, I've got buildfarm hosts with quite old OpenSSLs handy. What > tests do you want done, exactly? I would think that Peter is looking for tests which use SCRAM authentication over SSL with the following versions of OpenSSL used by the client: 1) Server at 1.0.1, client at 1.0.2, channel binding should not be used, authentication should succeed. 2) Server at 1.0.2, client at 1.0.1, here also channel binding should not be used, and connection should succeed. The patch changes the behavior of 2), which was failing as the client would use SCRAM_PLUS as SASL mechanism over SCRAM even if the client does not support channel binding. What I do in such cases is to compile OpenSSL by myself and link Postgres to it, here is a command to build shared libraries (all that is documented in INSTALL): =2E/config --prefix=3D$INSTALLPATH shared Another trick would be to comment out the sections in libpq where HAVE_PGTLS_GET_PEER_CERTIFICATE_HASH is used to emulate a compilation with OpenSSL 1.0.1 features and older, while still linking with 1.0.2. If you want to test the patch and check by yourself, that's of course fine by me. Just let me know when you are done and if you think the patch is good for commit. -- Michael --SLDf9lqlvOQaIe6s Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAlx1vzAACgkQnvQgOdby QH3kbA/+KE9ZqlLnq2E7KSsVaLby9ebA7EzavUZP+XjIrcF5y7bQoUaHwRpZ6tsG SCvc2vyC/hcWFR3Og3BRgZHDSoM6ZQtmXndKLwtidiVceJhH7KoZehSy5mPLRkA2 QPk+ttEpWBDT5b5nx/rzuZsDwvi6mW4genm/4joYkiIntR2dVYK96ILDaDeGBnk4 Jusw/wtlmWgYGuaYgOe9ilk2a6de8z5JdhS4zhb0MbLdcWODnWf5eKfpNnXKke6i MxQPotkcC1m/rwCWlwYy6sCr8R3XFpgTdpnqo6lH8cEkn/FuRnKMQZCcoWBuraxi w+DxM6HQ9wUU9ibgEQC3KMAN6j3nWY37XmPksXhmn+RFPj7ZgA7B3M0vIZ+X8Bs4 MhGpo6NxyRFSqnKzZIc6pVP7NFHa40D840tEvg7RhpV8xaIoCQIMoAdb0J0BxuPs R+Y2EnQkwv6da7srqZkXsLtdQkzypPjN7cvfEXnmS8bfxB8I+tmbT5/1ZYhmfTlq GvGA+zRW3hwfInEaiBjK+kGr9i5bKrEBsN4TJ81XBpNHYJ9EDcHCc8XnfkMXjUXx tde+0tOtaVJWBYtNNn37DEISK6hqFtmj5TntOl2eWtVtVz1soFWB8PWoWvgUWbot VChF1xjMdlsttcOgxyAyJuYQSJ56XBH7ChUwSwnXg+/ZxL3Tebs= =mEIc -----END PGP SIGNATURE----- --SLDf9lqlvOQaIe6s--