pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: heath.lord@crunchydata.com
Cc: Daniel Gustafsson <daniel@yesql.se>
Cc: Jacob Champion <jchampion@timescale.com>
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17625: In PG15 PQsslAttribute returns different values than PG14 when SSL is not in use for the connection
Date: Thu, 29 Sep 2022 15:49:58 -0400
Message-ID: <346263.1664480998@sss.pgh.pa.us> (raw)
In-Reply-To: <17625-fc47c78b7d71b534@postgresql.org>
References: <17625-fc47c78b7d71b534@postgresql.org>

PG Bug reporting form <noreply@postgresql.org> writes:
> According to the connection I am using, PQsslInUse is returning FALSE. 
> However, when I check the PQsslAttribute values, they are returning
> "OpenSSL, NULL, NULL, NULL, NULL".  In PostgreSQL 14, the library returns
> NULL when the connection is not using OpenSSL.

> It looks like commit ebc8b7d4416d8e0dfb7c05132ef6182fd3daf885 changed this
> behavior.

AFAICS that behavioral change is deliberate: for the single case
of inquiring about "library", PQsslAttribute now tells you which
SSL implementation libpq *can* use, not which one it's actually
using on a given connection.  I'm not sure that this is a great
definition, since it's so unlike the behavior for other attributes.
I can see the point of being able to check that, but should we
have invented a new function instead of overloading PQsslAttribute
this way?  One concrete point against this is that should we ever
be able to build libpq with the ability to use more than one GSS
library, this API would be utterly broken.

However, given that we're past rc1, I'm afraid that ship may have
sailed.  Assuming we leave it like this, how would you propose
changing the documentation to make it more clear?

			regards, tom lane





view thread (14+ messages)  latest in thread

Message-ID: <346263.1664480998@sss.pgh.pa.us>
Permalink:  ../346263.1664480998@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/346263.1664480998@sss.pgh.pa.us

 · 

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-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, heath.lord@crunchydata.com, daniel@yesql.se, jchampion@timescale.com, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #17625: In PG15 PQsslAttribute returns different values than PG14 when SSL is not in use for the connection
  In-Reply-To: <346263.1664480998@sss.pgh.pa.us>

* 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