Re: [PATCH] pglister: auth_receive: Indicate when PGAUTH_KEY is invalid instead of crashing - Mailing list pgsql-www

From Magnus Hagander
Subject Re: [PATCH] pglister: auth_receive: Indicate when PGAUTH_KEY is invalid instead of crashing
Date
Msg-id CABUevEyc_XzoUA7ML0pz37-AdR4vd16FzFeNxCtPb3=Wh3OFuw@mail.gmail.com
Whole thread Raw
In response to Re: [PATCH] pglister: auth_receive: Indicate when PGAUTH_KEY is invalid instead of crashing  (Célestin Matte <celestin.matte@cmatte.me>)
Responses Re: [PATCH] pglister: auth_receive: Indicate when PGAUTH_KEY is invalid instead of crashing  (Célestin Matte <celestin.matte@cmatte.me>)
List pgsql-www
On Mon, Feb 20, 2023 at 7:36 PM Célestin Matte <celestin.matte@cmatte.me> wrote:
>
> Update: attached patched also catch ValueError exceptions, which can happen as well.
>
> Also attaching similar patch for pgarchives.
>
> As being confused by the lack of error message happened to me again, I think these patches are useful.

It seems a patch like this was already merged into the upstream of
this, and got deployed into pgarchives & pglister when I synced those
up a couple of weeks ago. Sorry about the lateness of that one. Does
the current version of the code work for what you were looking for?

It might also be worth considering also checking explicitly for the
format of PGAUTH_KEY on startup. Something like the attached maybe?
(against pgweb which is the master of this file) What do you think?

--
 Magnus Hagander
 Me: https://www.hagander.net/
 Work: https://www.redpill-linpro.com/

Attachment

pgsql-www by date:

Previous
From: Magnus Hagander
Date:
Subject: Re: pgarchives: Bug report + Patches: loader can't handle message in multiple lists
Next
From: Palak Chaturvedi
Date:
Subject: Editor access to wiki