Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t16xQ-00Emd4-9l for pgsql-general@arkaria.postgresql.org; Wed, 16 Oct 2024 16:33:08 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1t16xO-005oOY-GQ for pgsql-general@arkaria.postgresql.org; Wed, 16 Oct 2024 16:33:06 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t16xO-005oNz-3v for pgsql-general@lists.postgresql.org; Wed, 16 Oct 2024 16:33:06 +0000 Received: from momjian.us ([72.94.173.45]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1t16xL-001Nww-Tn for pgsql-general@postgresql.org; Wed, 16 Oct 2024 16:33:05 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=momjian.us; s=2024011501; h=In-Reply-To:Content-Transfer-Encoding:Content-Type: MIME-Version:References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-ID:Content-Description; bh=stKIdUelzdQlPu9kxajdXYr2jHyRRYsglGYYfHQyqOM=; b=jcMXRltG9d9PfUb9IABBKol3Ef za8QGwf9JQS5wZP8jyQDcZPoxNqXbIwxD6OLDGnDTSpK4DEGDjZnxB/J+cEN5TNyMHTElY49QjDw5 pf7j6tByJbfpa65pwJ1/GGnd1RRq5TDJFWdJi/TUz51liZ5Y3SSXLIjagCRYI67tWElkNPs2pso7H 4pAmIAA/zx3oPGjTxixVVW2uMoeqZ5i3wdUQCWPkvcdA1sEG5JSUVO6obBKplKPk4TxRPNV/Z1jWe /HnDtrjUtyIFJO1mGMMAwmNt6RBTjLVx+MWXk0K+TyRbggYF72BnCeutieZ8d2JMoN5FRvKG7PPrt bjUxBZQA==; Received: from bruce by momjian.us with local (Exim 4.96) (envelope-from ) id 1t16xJ-008kiV-0t; Wed, 16 Oct 2024 12:33:01 -0400 Date: Wed, 16 Oct 2024 12:33:01 -0400 From: Bruce Momjian To: mbork@mbork.pl Cc: Dominique Devienne , pgsql-general@postgresql.org Subject: Re: What are best practices wrt passwords? Message-ID: References: <87o73kgzkd.fsf@mbork.pl> <87frowggzq.fsf@mbork.pl> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <87frowggzq.fsf@mbork.pl> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Oct 16, 2024 at 06:16:57PM +0200, mbork@mbork.pl wrote: > On 2024-10-16, at 14:41, Dominique Devienne wrote: > > > On Wed, Oct 16, 2024 at 2:25 PM wrote: > >> I'd like to be able to use psql without typing passwords again and > >> again. I know about `.pgpass` and PGPASSFILE, but I specifically do not > >> want to use it - I have the password in the `.env` file, and having it > >> in _two_ places comes with its own set of problems, like how to make > >> sure they don't get out of sync. > > > > What's wrong with PGPASSWORD? > > https://www.postgresql.org/docs/current/libpq-envars.html > > `ps auxe` shows all processes with their environments, no? I think that only shows for super-user. -- Bruce Momjian https://momjian.us EDB https://enterprisedb.com When a patient asks the doctor, "Am I going to die?", he means "Am I going to die soon?"