Re: Java .pgpass reader - Mailing list pgsql-jdbc

From Scott Langley
Subject Re: Java .pgpass reader
Date
Msg-id 4C19439A.90806@scharp.org
Whole thread Raw
In response to Re: Java .pgpass reader  (Chris Browne <cbbrowne@acm.org>)
List pgsql-jdbc
Hi Chris:

Would you be willing to share your code for this?

I'm still wanting to / planning to implement this for an individual JDBC
connection as the Java process that will use it runs once a week as a
cron job.

And to Radoslaw:

Your point about the relatively weak security of storing passwords in
.pgpass files is well-taken.  But I'm neither the SysAdmin nor the DBA
at where I work so I can't easily change policy.  However, we are at
least required to change our database passwords on a regular basis.

Scott

Chris Browne wrote:
> slangley@scharp.org (Scott Langley) writes:
>
>> Did anyone ever implement code in Java to read Postgres configuration
>> information from a user's .pgpass file - or a more general
>> pg_service.conf - as discussed in this thread back in 2006?
>>
>
> We've done this; it turned out to be something to do not at the level
> of an individual connection, but rather in a connection pool
> implementation.
>
> That turns out to be not so useful as a "general" solution that would
> be included in the JDBC driver :-(.
>


pgsql-jdbc by date:

Previous
From: Radosław Smogura
Date:
Subject: Re: Java .pgpass reader
Next
From: Kris Jurka
Date:
Subject: Re: pljava and postgresql 8.4.4 compile errors