Re: BUG #2931: Can't capture pg_dump Password prompt - Mailing list pgsql-bugs

From Magnus Hagander
Subject Re: BUG #2931: Can't capture pg_dump Password prompt
Date
Msg-id 45BB8F7F.3070604@hagander.net
Whole thread Raw
In response to BUG #2931: Can't capture pg_dump Password prompt  ("Michael Schmidt" <MichaelMSchmidt@msn.com>)
List pgsql-bugs
(please keep responses on the list)

Michael Schmidt wrote:
> Mr. Hagander,
> Thanks for taking the time to look at this.  Unfortunately, the 8.2
> documentation and information obtained from 'pg_dump --help' indicate
> PGPASSWORD is no longer available.  Using pgpass.conf creates
> cross-platform issues, as it is stored in different places on different
> systems.

It's definitly still available, see
http://www.postgresql.org/docs/8.2/static/libpq-envars.html.

It may not always be clear, but all the "libpq environment varilables"
apply to all the utilities that are based on libpq, which is pretty much
all of them.

I can see how using pgpass can be a cross platform problem. If you're
doing cross platform, you may have a security problem from PGPASSWORD
though - I don't know the detauls.


> While I understand that sending the Password: prompt to the console is a
> new "feature", the rationale in changing it from stderr is unclear.
> When it is on a *standard* stream it is - well - standard!  This good
> behavior is appreciated by at least one developer (me)!

It was changed to be consistent with Unix, IIRC.


> Given the issues with PGPASSWORD and password.conf, would you folks
> consider putting the Password: prompt back the way it was?

I doubt it. I don't hold a strong opinion myself, but I think it has
been proposed and rejected before.

//Magnus

pgsql-bugs by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: BUG #2934: INSTALL FAILURE - failed to set permissions
Next
From: Magnus Hagander
Date:
Subject: Re: BUG #2931: Can't capture pg_dump Password prompt