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 1iCnuP-00026M-DP for pgsql-hackers@arkaria.postgresql.org; Tue, 24 Sep 2019 16:43:25 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iCnuO-00088z-9H for pgsql-hackers@arkaria.postgresql.org; Tue, 24 Sep 2019 16:43:24 +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 1iCnuO-00088s-0h for pgsql-hackers@lists.postgresql.org; Tue, 24 Sep 2019 16:43:24 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iCnuL-0001Vw-T5 for pgsql-hackers@lists.postgresql.org; Tue, 24 Sep 2019 16:43:23 +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 x8OGhHXT022007; Tue, 24 Sep 2019 12:43:17 -0400 From: Tom Lane To: Victor Wagner cc: pgsql-hackers@lists.postgresql.org, Michael Paquier Subject: Re: PostgreSQL12 and older versions of OpenSSL In-reply-to: <20190924130731.2270332e@fafnir.local.vm> References: <20190924101859.09383b4f@fafnir.local.vm> <20190924094917.GB1982@paquier.xyz> <20190924130731.2270332e@fafnir.local.vm> Comments: In-reply-to Victor Wagner message dated "Tue, 24 Sep 2019 13:07:31 +0300" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <22005.1569343397.1@sss.pgh.pa.us> Date: Tue, 24 Sep 2019 12:43:17 -0400 Message-ID: <22006.1569343397@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Victor Wagner writes: > I'm attaching patch which uses solution mentioned above. > It seems that chedk for SSL_OP_NO_TLSvX_Y is redundant if > we are checking for TLS_MAX_VERSION. One thing I'm wondering is if it's safe to assume that TLS_MAX_VERSION will be defined whenever these other symbols are. Looking in an 0.9.8x install tree, that doesn't seem to define any of them; while in 1.0.1e I see ./tls1.h:#define TLS1_1_VERSION 0x0302 ./tls1.h:#define TLS1_2_VERSION 0x0303 ./tls1.h:#define TLS_MAX_VERSION TLS1_2_VERSION So the patch seems okay for these two versions, but I have no data about intermediate OpenSSL versions. BTW, the spacing in this patch seems rather random. regards, tom lane