Search Postgresql Archives

Re: specifying a password on the cmd line for db connect

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jasen Betts <jasen@xxxxxxxxxx> writes:
> On 2009-11-17, Ashesh Vashi <ashesh.vashi@xxxxxxxxxxxxxxxx> wrote:
>> You can always use the environment variable PGPASSWORD to do that.
>> Though - it is not recommended to use for security reason. :(

> as long as it's not in the default environment it's better than a
> command-line password.

On some platforms it's possible to see all of a process's environment
variables using ps-like tools.  That's why PGPASSWORD is deprecated.
If you're certain that your platform is not like this, then
"export PGPASSWORD=foo" is probably reasonably safe.  On the whole,
though, a .pgpass file is probably safer as well as more convenient.

			regards, tom lane

-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux