Re: pgsql: Remove support for OpenSSL older than 1.1.0

From: Daniel Gustafsson <daniel(at)yesql(dot)se>
To: Robins Tharakan <tharakan(at)gmail(dot)com>
Cc: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Remove support for OpenSSL older than 1.1.0
Date: 2024-09-03 11:36:50
Message-ID: 0047E121-A5F5-45C7-8A3D-3DD3FC880DC5@yesql.se
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

> On 3 Sep 2024, at 12:36, Robins Tharakan <tharakan(at)gmail(dot)com> 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).
>
> Could you point me on how to fix snakefly?
> (I've tried to disable SSL tests, but that doesn't seem to be helping).
>
> https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=snakefly&dt=2024-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 = 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

Attachment Content-Type Size
ssl_passphrase_skip.diff application/octet-stream 1.1 KB

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Alexander Korotkov 2024-09-03 13:07:11 Re: pgsql: Implement pg_wal_replay_wait() stored procedure
Previous Message Robins Tharakan 2024-09-03 10:36:24 Re: pgsql: Remove support for OpenSSL older than 1.1.0