pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Documentation improvements for PgJDBC
2+ messages / 2 participants
[nested] [flat]

* Documentation improvements for PgJDBC
@ 2010-05-20 03:49  Craig Ringer <craig@postnewspapers.com.au>
  0 siblings, 1 reply; 2+ messages in thread

From: Craig Ringer @ 2010-05-20 03:49 UTC (permalink / raw)
  To: pgsql-jdbc

Hi folks

It might save people some time and hassle if the PgJDBC docs referenced:

  http://java.sun.com/j2se/1.5.0/docs/guide/security/jsse/JSSERefGuide.html

where custom SSLSocketFactory implementations are discussed. It's quite
trivial to provide app-specific keystores and cert stores using
runtime-set java properties, to import user-supplied PKCS#12 certs for
client certificate use, etc, but only if you know where to look. The
JavaDoc for the JSSE API is ... lacking ... so references to good
starting points would really help.

It makes me uncomfortable that the only SSLSocketFactory provided by
Pg's JDBC Driver at the moment just disables server certificate
checking. If I get the chance I'll try to supply one that loads a
PKCS#12 client certificate, uses that for authentication, and uses the
certs from that and/or the standard Java cacerts to verify the server's
identity. I had an implementation earlier, but it turned out to
duplicate much of what the Java APIs do (once you know where to look) so
I'll be sending a greatly simplified single-class version for inclusion
in PgJDBC in a while.

In the mean time, adding some docs refs would IMO significantly improve
usability of the PgJDBC SSL features and help reduce the number of
people who just say "stuff it, I'll disable cert validation since that's
easy".

-- 
Craig Ringer

Tech-related writing: http://soapyfrogs.blogspot.com/



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: Documentation improvements for PgJDBC
@ 2010-05-20 13:34  Lew <noone@lewscanon.com>
  parent: Craig Ringer <craig@postnewspapers.com.au>
  0 siblings, 0 replies; 2+ messages in thread

From: Lew @ 2010-05-20 13:34 UTC (permalink / raw)
  To: pgsql-jdbc

Craig Ringer wrote:
> It might save people some time and hassle if the PgJDBC docs referenced:
>
>    http://java.sun.com/j2se/1.5.0/docs/guide/security/jsse/JSSERefGuide.html
>
> where custom SSLSocketFactory implementations are discussed.

OTOH, since Java 5 hit End-of-Life over two years ago

  !

it would be better to reference:
<http://java.sun.com/javase/6/docs/technotes/guides/security/jsse/JSSERefGuide.html;

-- 
Lew



^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2010-05-20 13:34 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2010-05-20 03:49 Documentation improvements for PgJDBC Craig Ringer <craig@postnewspapers.com.au>
2010-05-20 13:34 ` Lew <noone@lewscanon.com>

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