Re: Document spaces in .pgpass need to be escaped

From: James Coleman <jtc331(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Document spaces in .pgpass need to be escaped
Date: 2021-09-30 17:37:44
Message-ID: CAAaqYe_7vtx0nt5dVHsD5DraTJvYU9bDhLPD6EZrzEq3st+_vQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Sep 29, 2021 at 12:13 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>
> James Coleman <jtc331(at)gmail(dot)com> writes:
> > A coworker has a space in a Postgres password and noticed .pgpass
> > didn't work; escaping it fixed the issue. That requirement wasn't
> > documented (despite other escaping requirements being documented), so
> > I've attached a patch to add that comment.
>
> I looked at passwordFromFile() and I don't see any indication that
> it treats spaces specially. Nor does a quick test here confirm
> this report. So I'm pretty certain that this proposed doc change
> is wrong. Perhaps there's some other issue to investigate, though?
>
> regards, tom lane

Thanks for taking a look.

I'm honestly not sure what happened here. I couldn't reproduce again
either, and on another box with this coworker we could reproduce, but
then realized the pgpass entry was missing a field. I imagine it must
have been similar on the original box we observed the error on, but
both of our memories were of just adding teh escape characters...

I'll mark the CF entry as withdrawn.

Thanks,
James Coleman

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Drouvot, Bertrand 2021-09-30 18:07:01 Re: [BUG] failed assertion in EnsurePortalSnapshotExists()
Previous Message Jaime Casanova 2021-09-30 17:25:07 Re: Numeric x^y for negative x