Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oeH1a-0004KN-CQ for pgsql-bugs@arkaria.postgresql.org; Fri, 30 Sep 2022 14:29:58 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1oeH1Z-0001Sr-3i for pgsql-bugs@arkaria.postgresql.org; Fri, 30 Sep 2022 14:29:57 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oeH1Y-0001Si-Nk for pgsql-bugs@lists.postgresql.org; Fri, 30 Sep 2022 14:29:56 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oeH1S-0005ay-8w for pgsql-bugs@lists.postgresql.org; Fri, 30 Sep 2022 14:29:55 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.15.2/8.15.2) with ESMTP id 28UETlOY640452; Fri, 30 Sep 2022 10:29:48 -0400 From: Tom Lane To: Daniel Gustafsson cc: Jacob Champion , heath.lord@crunchydata.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: <5DD276A1-87D1-41D3-A9F1-4C0B6F5DAD48@yesql.se> References: <17625-fc47c78b7d71b534@postgresql.org> <346263.1664480998@sss.pgh.pa.us> <360379.1664482591@sss.pgh.pa.us> <395956.1664484332@sss.pgh.pa.us> <398499.1664485687@sss.pgh.pa.us> <8F5DD45F-8A0D-4CBE-93B9-844C55886B85@yesql.se> <467714.1664488691@sss.pgh.pa.us> <5DD276A1-87D1-41D3-A9F1-4C0B6F5DAD48@yesql.se> Comments: In-reply-to Daniel Gustafsson message dated "Fri, 30 Sep 2022 00:11:42 +0200" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <640450.1664548187.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Fri, 30 Sep 2022 10:29:47 -0400 Message-ID: <640451.1664548187@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Daniel Gustafsson writes: > On 29 Sep 2022, at 23:58, Tom Lane wrote: >> - Returns an array of SSL attribute names available. >> + Returns an array of SSL attribute names that can be used >> + in PQsslAttribute(). > Maybe hairsplitting, but should we note that it can be used in PQsslAttr= ibute() > for the conn which was passed as param to PQsslAttributeNames()? In a (= still > hypothetical) multi-library case there is no guarantee that it will be v= alid > for another conn. I thought about doing this, but the subsequent para seems to make it clear enough: + + If conn is NULL, the attributes available for t= he + default SSL library are returned, or an empty list + if libpq was compiled without any SSL + support. If conn is not NULL, the attributes + available for the SSL library in use for the connection are return= ed, + or an empty list if the connection is not encrypted. + The actual constraint is "names that can be used on connections using the same SSL library", which seems too verbose for the introductory sentence. > I'd be fine just doing this in HEAD. Pushed to HEAD only. regards, tom lane