Re: Improve error handling of HMAC computations and SCRAM

From: Michael Paquier <michael(at)paquier(dot)xyz>
To: Sergey Shinderuk <s(dot)shinderuk(at)postgrespro(dot)ru>
Cc: Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Improve error handling of HMAC computations and SCRAM
Date: 2022-01-13 07:24:31
Message-ID: Yd/
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Thu, Jan 13, 2022 at 02:01:24AM +0300, Sergey Shinderuk wrote:
> Gave it a thorough read. Looks good, except for errstr not set in a couple
> of places (see the diff attached).

Thanks for the review. The comments about pg_hmac_ctx->data were
wrong from the beginning, coming, I guess, from one of the earlier
patch versions where this was discussed. So I have applied that

I have also spent a good amount of time on that to close the loop and
make sure that no code paths are missing an error context, adjusted a
couple of comments to explain more the role of *errstr in all the
SCRAM routines, and finally applied it on HEAD.

In response to


Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2022-01-13 07:30:23 Re: 2022-01 Commitfest
Previous Message Alexander Lakhin 2022-01-13 07:00:00 Re: Why is src/test/modules/committs/t/ flaky?