Re: BUG #10347: Can't write password to psql or pg_dump - Mailing list pgsql-bugs

From hubert depesz lubaczewski
Subject Re: BUG #10347: Can't write password to psql or pg_dump
Date
Msg-id 20140518101530.GA13617@depesz.com
Whole thread Raw
In response to BUG #10347: Can't write password to psql or pg_dump  (derek_ealy@rapid7.com)
List pgsql-bugs
On Fri, May 16, 2014 at 08:34:09PM +0000, derek_ealy@rapid7.com wrote:
> When exec'ing a command to pg_dump or psql from Java there is no "normal"
> way to send the password to the psql process.
>=20
> On Linux systems it works as expected because I write the password to the
> input stream of the process running psql.

Normal way of providing password is either to use PGPASSWORD environment
variable, as shown here:
http://www.postgresql.org/docs/current/interactive/libpq-envars.html
or pgpass file, as shown here:
http://www.postgresql.org/docs/current/interactive/libpq-pgpass.html

depesz

pgsql-bugs by date:

Previous
From: derek_ealy@rapid7.com
Date:
Subject: BUG #10347: Can't write password to psql or pg_dump
Next
From: Andres Freund
Date:
Subject: Re: BUG #10347: Can't write password to psql or pg_dump