pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Fix memory leak when rejecting bogus DH parameters.
Date: Sat, 20 Mar 2021 16:48:06 +0000
Message-ID: <E1lNeli-0004vX-V1@gemulon.postgresql.org> (raw)

Fix memory leak when rejecting bogus DH parameters.

While back-patching e0e569e1d, I noted that there were some other
places where we ought to be applying DH_free(); namely, where we
load some DH parameters from a file and then reject them as not
being sufficiently secure.  While it seems really unlikely that
anybody would hit these code paths in production, let alone do
so repeatedly, let's fix it for consistency.

Back-patch to v10 where this code was introduced.

Discussion: https://postgr.es/m/16160-18367e56e9a28264@postgresql.org

Branch
------
REL_12_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/2f31414f4322876b34674eedc6e7d19c29ebe0d0

Modified Files
--------------
src/backend/libpq/be-secure-openssl.c | 3 +++
1 file changed, 3 insertions(+)



view thread (5+ messages)  latest in thread

Message-ID: <E1lNeli-0004vX-V1@gemulon.postgresql.org>
Permalink:  ../E1lNeli-0004vX-V1@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1lNeli-0004vX-V1@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 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: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Fix memory leak when rejecting bogus DH parameters.
  In-Reply-To: <E1lNeli-0004vX-V1@gemulon.postgresql.org>
  References: <E1lNeli-0004vX-V1@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