From: Guillaume Cottenceau <gc@mnc.ch>
To: Kris Jurka <books@ejurka.com>
Cc: Saleem EDAH-TALLY <nmset@netcourrier.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: SSL - Providing client certificates
Date: Mon, 23 Feb 2009 12:25:40 +0100
Message-ID: <87iqn1v1hn.fsf@meuh.mnc.lan> (raw)
In-Reply-To: <Pine.BSO.4.64.0902201226580.23634@leary.csoft.net>
References: <200902201030.33352.nmset@netcourrier.com>
<Pine.BSO.4.64.0902201226580.23634@leary.csoft.net>
Kris Jurka <books 'at' ejurka.com> writes:
> On Fri, 20 Feb 2009, Saleem EDAH-TALLY wrote:
>
>> However, if we set javax.net.ssl.keyStore and javax.net.ssl.keyStorePassword,
>> the SSL connection is established and the client certificate is verified.
>>
>
> When the code was first written, this wasn't tested and it was just
> assumed that it wouldn't work. Recently we got a report that it did
> work, but the documentation was not updated.
>
> What I don't understand is how it selects the certificate to send. If
> you have multiple keys in your keystore, how do you indicate which one
> to use?
My quite limited understanding of the behaviour of SSL client
authentication may potentially help a little:
You initially send a certificate signing request to the
admin/owner of the server (signed with your private key); when
you receive the certificate reply (signed with their private
key), you can build a chain of trust between you and the server,
your keystore will look like:
Entry type: PrivateKeyEntry
Certificate chain length: 2
Certificate[1]:
Owner: <you>
Issuer: <server>
Certificate[2]:
Owner: <server>
Issuer: <server>
Then at the SSL handshake time, first the server presents his
certificate, second it asks for a client certificate, at that
time you are able to present the certificate belonging to the
chain of trust containing the server certificate on top.
--
Guillaume Cottenceau
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-jdbc@postgresql.org
Cc: gc@mnc.ch, books@ejurka.com, nmset@netcourrier.com
Subject: Re: SSL - Providing client certificates
In-Reply-To: <87iqn1v1hn.fsf@meuh.mnc.lan>
References: <200902201030.33352.nmset@netcourrier.com> <Pine.BSO.4.64.0902201226580.23634@leary.csoft.net> <87iqn1v1hn.fsf@meuh.mnc.lan>
* 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