Re: BUG #15932: Module passwordcheck doesn't reference previous hooks - Mailing list pgsql-bugs

From Michael Paquier
Subject Re: BUG #15932: Module passwordcheck doesn't reference previous hooks
Date
Msg-id 20190730022420.GC1742@paquier.xyz
Whole thread Raw
In response to BUG #15932: Module passwordcheck doesn't reference previous hooks  (PG Bug reporting form <noreply@postgresql.org>)
Responses Re: BUG #15932: Module passwordcheck doesn't reference previous hooks  (Michael Paquier <michael@paquier.xyz>)
List pgsql-bugs
On Mon, Jul 29, 2019 at 03:56:35PM +0000, PG Bug reporting form wrote:
> Module passwordcheck doesn't reference (thus, doesn't call) previous
> hooks:
>
> https://github.com/postgres/postgres/blob/master/contrib/passwordcheck/passwordcheck.c#L133
>
> As a result, if passwordcheck is used hook check_password_hook becomes
> useless.

So, it would erase the trace of previous hooks if loaded last.
passwordcheck holds value as an example of use for some hooks, and
examples should be a good students, so I agree to do better and fix
that.  The attached patch does the work, what do you think about it?
--
Michael

Attachment

pgsql-bugs by date:

Previous
From: Georg Sauthoff
Date:
Subject: Re: BUG #15930: Redact PGPASSWORD environment variable in psql
Next
From: Michael Paquier
Date:
Subject: Re: BUG #15930: Redact PGPASSWORD environment variable in psql