From: Andrew Dunstan <andrew@dunslane.net>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Provide a TLS init hook
Date: Wed, 25 Mar 2020 21:32:18 +0000
Message-ID: <E1jHDdK-0002YP-15@gemulon.postgresql.org> (raw)
Provide a TLS init hook
The default hook function sets the default password callback function.
In order to allow preloaded libraries to have an opportunity to override
the default, TLS initialization if now delayed slightly until after
shared preloaded libraries have been loaded.
A test module is provided which contains a trivial example that decodes
an obfuscated password for an SSL certificate.
Author: Andrew Dunstan
Reviewed By: Andreas Karlsson, Asaba Takanori
Discussion: https://postgr.es/m/04116472-818b-5859-1d74-3d995aab2252@2ndQuadrant.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/896fcdb230e729652d37270c8606ccdc45212f0d
Modified Files
--------------
src/backend/libpq/be-secure-openssl.c | 48 +++++++-----
src/backend/postmaster/postmaster.c | 22 +++---
src/include/libpq/libpq-be.h | 4 +
src/test/modules/Makefile | 5 ++
.../modules/ssl_passphrase_callback/.gitignore | 1 +
src/test/modules/ssl_passphrase_callback/Makefile | 24 ++++++
.../modules/ssl_passphrase_callback/server.crt | 19 +++++
.../modules/ssl_passphrase_callback/server.key | 30 ++++++++
.../ssl_passphrase_callback/ssl_passphrase_func.c | 88 ++++++++++++++++++++++
.../ssl_passphrase_callback/t/001_testfunc.pl | 80 ++++++++++++++++++++
src/tools/msvc/Mkvcbuild.pm | 2 +-
11 files changed, 292 insertions(+), 31 deletions(-)
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: andrew@dunslane.net
Subject: Re: pgsql: Provide a TLS init hook
In-Reply-To: <E1jHDdK-0002YP-15@gemulon.postgresql.org>
References: <E1jHDdK-0002YP-15@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