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

From: Greg Smith <greg(at)2ndquadrant(dot)com>
To: "Gauthier, Dave" <dave(dot)gauthier(at)intel(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: specifying a password on the cmd line for db connect
Date: 2009-11-16 23:04:51
Message-ID: 4B01DA93.3090403@2ndquadrant.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Gauthier, Dave wrote:
>
> Hi:
>
>
>
> Is there a way to require and specify a password at the cmd line for a
> connect?
>
You don't want to do that because any user on the system can see the
command, and thus the password. You want to use a .pgpass file instead:

http://www.postgresql.org/docs/8.4/interactive/libpq-pgpass.html

--
Greg Smith 2ndQuadrant Baltimore, MD
PostgreSQL Training, Services and Support
greg(at)2ndQuadrant(dot)com www.2ndQuadrant.com

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Raymond O'Donnell 2009-11-16 23:05:58 Re: specifying a password on the cmd line for db connect
Previous Message Gauthier, Dave 2009-11-16 22:51:41 specifying a password on the cmd line for db connect