pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter@eisentraut.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Convert encrypted SSL test keys to PKCS#8 format
Date: Mon, 28 Aug 2023 05:38:28 +0000
Message-ID: <E1qaUxH-001IXG-L4@gemulon.postgresql.org> (raw)

Convert encrypted SSL test keys to PKCS#8 format

OpenSSL in FIPS mode rejects several encrypted private keys used in
the test suites ssl and ssl_passphrase_callback.  This is because they
are in a "traditional" OpenSSL format that uses MD5 for key
generation.  The fix is to convert them to the more standard PKCS#8
format that uses SHA1 for key derivation.

This commit contains the converted keys, with the conversion done like
this:

openssl pkcs8 -topk8 -in src/test/modules/ssl_passphrase_callback/server.key -passin pass:FooBaR1 -out src/test/modules/ssl_passphrase_callback/server.key.new -passout pass:FooBaR1
mv src/test/modules/ssl_passphrase_callback/server.key.new src/test/modules/ssl_passphrase_callback/server.key

etc., as well as updated build rules to generate the keys in the new
format if they need to be regenerated.

Reviewed-by: Jacob Champion <jchampion@timescale.com>
Discussion: https://www.postgresql.org/message-id/flat/64de784b-8833-e055-3bd4-7420e6675351%40eisentraut.org

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/648c72956f980771c5a3686ee68c5e2c5b62a534

Modified Files
--------------
src/test/modules/ssl_passphrase_callback/Makefile  |  2 +-
.../modules/ssl_passphrase_callback/meson.build    |  2 +-
.../modules/ssl_passphrase_callback/server.key     | 60 +++++++++++-----------
src/test/ssl/ssl/client-encrypted-pem.key          | 60 +++++++++++-----------
src/test/ssl/ssl/server-password.key               | 60 +++++++++++-----------
src/test/ssl/sslfiles.mk                           |  4 +-
6 files changed, 94 insertions(+), 94 deletions(-)



Message-ID: <E1qaUxH-001IXG-L4@gemulon.postgresql.org>
Permalink:  ../E1qaUxH-001IXG-L4@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1qaUxH-001IXG-L4@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-committers@postgresql.org
  Cc: peter@eisentraut.org, pgsql-committers@lists.postgresql.org
  Subject: Re: pgsql: Convert encrypted SSL test keys to PKCS#8 format
  In-Reply-To: <E1qaUxH-001IXG-L4@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox