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 1slRqM-007oJ8-MC for pgsql-committers@arkaria.postgresql.org; Tue, 03 Sep 2024 11:37:07 +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 1slRqL-00AoNe-Oz for pgsql-committers@arkaria.postgresql.org; Tue, 03 Sep 2024 11:37:05 +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 1slRqL-00AoNW-FD for pgsql-committers@lists.postgresql.org; Tue, 03 Sep 2024 11:37:05 +0000 Received: from smtp.outgoing.loopia.se ([93.188.3.37]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1slRqH-000S78-W3 for pgsql-committers@lists.postgresql.org; Tue, 03 Sep 2024 11:37:04 +0000 Received: from s807.loopia.se (localhost [127.0.0.1]) by s807.loopia.se (Postfix) with ESMTP id DF4C6B8ECE for ; Tue, 03 Sep 2024 13:37:00 +0200 (CEST) Received: from s899.loopia.se (unknown [172.22.191.5]) by s807.loopia.se (Postfix) with ESMTP id CEFC9BA725; Tue, 03 Sep 2024 13:37:00 +0200 (CEST) Received: from s471.loopia.se (unknown [172.22.191.6]) by s899.loopia.se (Postfix) with ESMTP id CD9442C8BA66; Tue, 03 Sep 2024 13:37:00 +0200 (CEST) X-Virus-Scanned: amavisd-new at amavis.loopia.se X-Spam-Flag: NO X-Spam-Score: -1.2 X-Spam-Level: X-Spam-Status: No, score=-1.2 tagged_above=-999 required=6.2 tests=[ALL_TRUSTED=-1, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1] autolearn=disabled Authentication-Results: s471.loopia.se (amavisd-new); dkim=pass (2048-bit key) header.d=yesql.se Received: from s899.loopia.se ([172.22.191.5]) by s471.loopia.se (s471.loopia.se [172.22.190.35]) (amavisd-new, port 10024) with LMTP id dr7N5JWMnU33; Tue, 3 Sep 2024 13:37:00 +0200 (CEST) X-Loopia-Auth: user X-Loopia-User: daniel@yesql.se X-Loopia-Originating-IP: 89.255.232.193 Received: from smtpclient.apple (customer-89-255-232-193.stosn.net [89.255.232.193]) (Authenticated sender: daniel@yesql.se) by s899.loopia.se (Postfix) with ESMTPSA id 54B6C2C8BA9A; Tue, 03 Sep 2024 13:37:00 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yesql.se; s=loopiadkim1707475645; t=1725363420; bh=jZH8ET1173hM4okDzY0y5F1yBGEzzVwKMje308KF9r8=; h=From:Subject:Date:In-Reply-To:Cc:To:References; b=WlQdT5wAein7QGMMtDNNT/xby+9vHX/SjZCFCQP9O/1OOI9UAmoT/zQgCNtpgmSdD PPd2Wkic6HoLlPFMEhKnYpNRWmbKMw+6NXCOYnZ7FCls3ln5rliCLQaYnSiLkHgcXM iV64vdphwPLj2Vk1nL3YX1tjiHct4HfgRLAy4TKzP3OarjhLZ+2cziZBvrw3W1YS2h 6cSUtlGA233hhdx31sDFlWWSqpVxU0pQqMG2AQ1hEGH3bxRW7SSeycVVJy+vcdW76d E0u0zVHFDELTdMvWKbWXafYDOe9iyg7OfXf7y8Trs+dYtFzFP8Wpj+XFR26YFHWQTS rT3pL4Ahz9P4A== From: Daniel Gustafsson Message-Id: <0047E121-A5F5-45C7-8A3D-3DD3FC880DC5@yesql.se> Content-Type: multipart/mixed; boundary="Apple-Mail=_B22E8F1E-C617-4339-9E8C-D38E71387850" Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3774.600.62\)) Subject: Re: pgsql: Remove support for OpenSSL older than 1.1.0 Date: Tue, 3 Sep 2024 13:36:50 +0200 In-Reply-To: Cc: pgsql-committers@lists.postgresql.org To: Robins Tharakan References: X-Mailer: Apple Mail (2.3774.600.62) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk --Apple-Mail=_B22E8F1E-C617-4339-9E8C-D38E71387850 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii > On 3 Sep 2024, at 12:36, Robins Tharakan wrote: > I am trying to update my buildfarm animals for this, and although I = fixed massasauga (essentially by skipping the test for now), I am = unclear why snakefly still fails (now, much later into the cycle).=20 >=20 > Could you point me on how to fix snakefly?=20 > (I've tried to disable SSL tests, but that doesn't seem to be = helping). >=20 > = https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=3Dsnakefly&dt=3D20= 24-09-03%2009%3A56%3A46 The BF run entry claims it's failing in the ssl_passphrase_callbackCheck = stage which is odd, since without SSL it shouldn't recurse into that test = module at all. Looking at massasauga it did recurse into there but then subsequently = skipped the test due to OpenSSL being missing. However, it would first need to = compile the test module in order to reach the SKIP statement in the TAP test, = and I believe that's where snakefly is failing. If I recompile postgres = without SSL and ensure that it cannot see any OpenSSL headers via standard includes = I can reproduce the error, the excerpt from install.log being the expected compilation failure: ssl_passphrase_func.c:29:23: error: unknown type name 'SSL_CTX' static void set_rot13(SSL_CTX *context, bool isServerStart); ^ ssl_passphrase_func.c:52:3: error: use of undeclared identifier = 'openssl_tls_init_hook' openssl_tls_init_hook =3D set_rot13; ^ ssl_passphrase_func.c:56:11: error: unknown type name 'SSL_CTX' set_rot13(SSL_CTX *context, bool isServerStart) ^ ssl_passphrase_func.c:63:2: error: call to undeclared function = 'SSL_CTX_set_default_passwd_cb'; ISO C99 and later do not support = implicit function declarations [-Wimplicit-function-declaration] SSL_CTX_set_default_passwd_cb(context, rot13_passphrase); ^ 4 errors generated. Does massasauga have OpenSSL headers such that the compiler can find = them via standard includes, and snakefly doesn't? The buildfarm client should honor the rules in the src/test/modules = Makefile which skips the subdirectory when OpenSSL isn't present, but since the = TAP test have a SKIP clause I guess we should support it. The attached diff = fixes it for me, are you able to test that on snakefly? -- Daniel Gustafsson --Apple-Mail=_B22E8F1E-C617-4339-9E8C-D38E71387850 Content-Disposition: attachment; filename=ssl_passphrase_skip.diff Content-Type: application/octet-stream; x-unix-mode=0644; name="ssl_passphrase_skip.diff" Content-Transfer-Encoding: 7bit diff --git a/src/test/modules/ssl_passphrase_callback/ssl_passphrase_func.c b/src/test/modules/ssl_passphrase_callback/ssl_passphrase_func.c index d599214982..b0d1fd2f70 100644 --- a/src/test/modules/ssl_passphrase_callback/ssl_passphrase_func.c +++ b/src/test/modules/ssl_passphrase_callback/ssl_passphrase_func.c @@ -25,8 +25,10 @@ static char *ssl_passphrase = NULL; /* callback function */ static int rot13_passphrase(char *buf, int size, int rwflag, void *userdata); +#ifdef USE_SSL /* hook function to set the callback */ static void set_rot13(SSL_CTX *context, bool isServerStart); +#endif /* * Module load callback @@ -48,10 +50,13 @@ _PG_init(void) MarkGUCPrefixReserved("ssl_passphrase"); +#ifdef USE_SSL if (ssl_passphrase) openssl_tls_init_hook = set_rot13; +#endif } +#ifdef USE_SSL static void set_rot13(SSL_CTX *context, bool isServerStart) { @@ -62,6 +67,7 @@ set_rot13(SSL_CTX *context, bool isServerStart) SSL_CTX_set_default_passwd_cb(context, rot13_passphrase); } +#endif static int rot13_passphrase(char *buf, int size, int rwflag, void *userdata) --Apple-Mail=_B22E8F1E-C617-4339-9E8C-D38E71387850--