Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id A6A7BB5DC14 for ; Tue, 24 May 2011 22:40:06 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 38220-10 for ; Wed, 25 May 2011 01:39:59 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from www.postnewspapers.com.au (www.postnewspapers.com.au [173.230.139.50]) by mail.postgresql.org (Postfix) with ESMTP id 7F4ABB5DBDA for ; Tue, 24 May 2011 22:39:59 -0300 (ADT) Received: from localhost (localhost [127.0.0.1]) by www.postnewspapers.com.au (Postfix) with ESMTP id 697382D; Tue, 24 May 2011 21:39:59 -0400 (EDT) X-Virus-Scanned: amavisd-new at postnewspapers.com.au.com Received: from www.postnewspapers.com.au ([127.0.0.1]) by localhost (www.postnewspapers.com.au [127.0.0.1]) (amavisd-new, port 10024) with LMTP id uuD4oZMeRNr8; Tue, 24 May 2011 21:39:58 -0400 (EDT) Received: from mail.postnewspapers.com.au (ppp171-128.static.internode.on.net [150.101.171.128]) by www.postnewspapers.com.au (Postfix) with ESMTP id 5F63A27; Tue, 24 May 2011 21:39:58 -0400 (EDT) Received: from [10.0.0.53] (wallace.localnet [10.0.0.53]) by mail.postnewspapers.com.au (Postfix) with ESMTP id 5B1B1AE9BB; Wed, 25 May 2011 09:39:57 +0800 (WST) Message-ID: <4DDC5DED.7010903@postnewspapers.com.au> Date: Wed, 25 May 2011 09:39:57 +0800 From: Craig Ringer User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.15) Gecko/20110307 Thunderbird/3.1.9 MIME-Version: 1.0 To: Kris Jurka CC: =?ISO-8859-1?Q?Marc-Andr=E9_Laverdi=E8re?= , pgsql-jdbc@postgresql.org Subject: Re: Support for cert auth in JDBC References: <4DD34FE5.3020609@atc.tcs.com> <4DD35BEA.3020902@postnewspapers.com.au> <4DD361CA.3070907@atc.tcs.com> <4DD36EFC.6070707@postnewspapers.com.au> <4DD379C5.1030703@atc.tcs.com> <4DD3C751.5080908@postnewspapers.com.au> <4DD4AED1.2080008@postnewspapers.com.au> <4DD4B535.1050707@atc.tcs.com> <4DDB3A6A.3000608@atc.tcs.com> In-Reply-To: X-Enigmail-Version: 1.1.2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.91 tagged_above=-10 required=5 tests=BAYES_00=-1.9, T_RP_MATCHES_RCVD=-0.01 X-Spam-Level: X-Archive-Number: 201105/77 X-Sequence-Number: 21907 On 25/05/11 00:27, Kris Jurka wrote: > > > On Tue, 24 May 2011, Marc-Andr? Laverdi?re wrote: > >> It is not over... It is not in the CVS repository yet :D >> >> What would be the next step? > > It was not clear to me that the discussion between you and Craig had > resulted in a final code version. Apparently you think so. Craig do > you concur? I'm happy with the state of the code, but should really test it properly before signing off on that. In particular, I need to test PKCS#12 cert files and test a JECKS keystore containing multiple keys only one of which is valid to access Pg. On the other hand, I'm swamped at the moment and unsure if I'll get to that in a reasonable amount of time. The tests Marc-André wrote demonstrate the core functionality pretty well, and the code would be good to get into the official codebase to save others from duplicating the same work over and over as both Marc-André and I have each done already. Argh. I'm going to have to come back to that, as I have a backup server to fix. Maybe it's best if you have a look and see what you think of it, while I try to find some time to do some more testing. > Perhaps some documentation updates > would be in order, but I haven't looked at the code yet to know what > might be appropriate. Some documentation updates are definitely in order, to sit alongside the existing documentation for the non-validating ssl factory. By the way, I _do_ think it'd be useful to add support for constructing the socket factory with: FactoryClass(String arg, Properties jdbcProperties) ... where the properties argument contains all the Pg JDBC properties like the user name and password. It'd make it easier for apps to pass custom args into a socket factory, especially things like the password to the user's private key that they don't want to have to put in the sslocketfactoryarg string. I could also then produce a second version of the cert factory for people to use that got all its settings from the jdbc connection properties instead of the sytem properties. I wouldn't suggest adding that now, though, but maybe as a revision once the working code is already committed. -- Craig Ringer