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 1g0I2S-0001hQ-5l for pgsql-general@arkaria.postgresql.org; Thu, 13 Sep 2018 03:11:29 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g0I2Q-0003j6-IU for pgsql-general@arkaria.postgresql.org; Thu, 13 Sep 2018 03:11:26 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0I2O-0003iu-N2 for pgsql-general@lists.postgresql.org; Thu, 13 Sep 2018 03:11:26 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g0I2K-0006bD-NS for pgsql-general@lists.postgresql.org; Thu, 13 Sep 2018 03:11:23 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 3215B21F30; Wed, 12 Sep 2018 23:11:19 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Wed, 12 Sep 2018 23:11:19 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=vo/TMYql3AvwKeqz+uDmF9idnTl8CpIhWMbT/sHW6x8=; b=Cwk4uWMk 8vrxtkeq+qeafyX2HUqAbzWJtqOR09Vzr/XBNDXd0aBZ8BjtgHV3D/Lv4MRQrLoS JUuZV4SPFrsXhDWK1OE+2hdrg00wuASBPeXcoqw0XXGY75rS2Eyybyq7C1bZQHgy fMmurqHzEq2Df9nz85MkCq07MiO9VIHUF9GiLB0RkGXIo7vr1lt8EPR0LRmPY53K BWz7tDhoV6WN+zhwH88EzI2ROXAxQpXyVFNmxK6TcmjBvkhjO5iG8mG0E5J45Wp0 AAYILrka6pkFplLzFVyHb8oAKR1bBadKqGgwGjhbZKZKTLG0HxKJhGJRXoVVyqko aG4PSVptHtFsWA== 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-sender :x-me-sender:x-sasl-enc; s=fm3; bh=vo/TMYql3AvwKeqz+uDmF9idnTl8C pIhWMbT/sHW6x8=; b=Bxqg3g1rPA4ajYpUrGE8KKnbRMv2N4J9RzwQx8lwHQJ7S p+TrlJxiSCEozXFg1xHC6WNydd4hHixlPFYUSsl2fZLivYdDbj29+zrVm+2IvpAb JgaZhbTwGePYCOxfzUFwxznQYq9FE6SPMGhNJtn8U92wXTANfhRPOjO2Fll2B9Sm c5X1ESAF4V92nPPTiP5rjWNCvzSb1/Aw4l+Iy6zmTCMgiJODInlRFgNrG7sPXlyD mmYhDdp3CmACFT15OpeTauG3NM71k/Vf7uJQQwWhO1+vA3hkaF+Z5yzevwA3F19g 2kQWM+4tM40QvkaNFpTNszqFQT/N3nPNt6kL2bxGg== X-ME-Proxy: X-ME-Sender: Received: from paquier.xyz (c137162.net61215.cablenet.ne.jp [61.215.137.162]) by mail.messagingengine.com (Postfix) with ESMTPA id 5076DE44DF; Wed, 12 Sep 2018 23:11:17 -0400 (EDT) Date: Thu, 13 Sep 2018 12:11:14 +0900 From: Michael Paquier To: Peter Eisentraut Cc: Alessandro Gherardi , "pgsql-general@lists.postgresql.org" Subject: Re: scram-sha-256 authentication broken in FIPS mode Message-ID: <20180913031114.GA3578@paquier.xyz> References: <898098721.1290085.1536118171911@mail.yahoo.com> <20180905042717.GL20696@paquier.xyz> <767499000.1481233.1536153579656@mail.yahoo.com> <20180905181545.GC2726@paquier.xyz> <1691863835.972001.1536301001998@mail.yahoo.com> <1924578892.946938.1536301653576@mail.yahoo.com> <1168852455.1352488.1536591120175@mail.yahoo.com> <20180911030250.GA27115@paquier.xyz> <5aeb058d-e32c-e3e0-e4b1-6469aeeadc2b@2ndquadrant.com> <20180911222424.GB25160@paquier.xyz> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="fUYQa+Pmc3FrFX/N" Content-Disposition: inline In-Reply-To: <20180911222424.GB25160@paquier.xyz> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --fUYQa+Pmc3FrFX/N Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Sep 12, 2018 at 07:24:24AM +0900, Michael Paquier wrote: > Good point. Such things have bitten in the past. Okay, then let's do > something about sha2_openssl.c only on HEAD for now then, which I am > fine to finish wrapping. I was looking at trying to commit this patch, however more needs to be done in terms of error handling, as the proposed patch would happily crash if EVP_MD_CTX cannot be allocated (understand OOM) in EVP_DigestInit_ex if I read the OpenSSL code correctly (see crypto/evp/digest.c). Our lives would be facilitated if it was possible to use directly EVP_MD_CTX and EVP_MD_CTX_init so as no allocation is done but that's not doable as of 1.0.2. -- Michael --fUYQa+Pmc3FrFX/N Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAluZ1VIACgkQnvQgOdby QH1BrQ//QUe7No7/Ns9qsA7SYOy2Pg0nAwqmm7tPKYF3MjJv0d6XTADsvcFfzFsB VMH69c3FuqYa7Db6TPVQv5LDEsaBri/OfMVwcVARUxO628wZO7/CyEtGdasQ0ebV V6ztamDlKHHYsblgtih/TgE8FWIMU2o4WhDH2Of6FV7pSXFycv6KO36+YVUmBZSE 8ONREPQAq7hhuRm3lqWgFNbb9dZW/Om2UwBow572n8HG+cfXM/0FkSn8Kvumg0c8 /1PjvpGPt78T6vcfdw4RRt+58pIyEoYV/6Q3F9d9xC6HSlFmO6C7WjBQIFt/xQGC LeTVO0HZGfvDeQRchQup1OTM2zAikc3DwIRg54MwuGqlVmCbXyI9wXEkPdVAxs1k aDwLTjMcLyodwi9M3Bmvnw0tbGpAI1WwS5GzUJlrhM5Cr1xCDtAIpCGuY2+Tb4RP id/VQ+69E/lBrNqNp2ye74cThmPJ7DCec5Tj+KFx85eAwnExnmof8FS6L9dvNRZb V/S36WRLq64EzTrsrKsmeTyJOw5QQ0chQursoYulGnFn6aBPBEb12U1Lql/6YyQP TdJLuZIaI2GaH90kEBoS2XzjeWbL8BRSSC9W9QNpyHRdrK90mP9pCPSvpN4wQLSE h4Tyd09PhrfF+6tdltWsr3aua4CJ7Xt9bhufSNO9r0NndzYYzBY= =ST9Q -----END PGP SIGNATURE----- --fUYQa+Pmc3FrFX/N--