Re: scram and \password

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: scram and \password
Date: 2017-03-10 22:43:57
Message-ID: CAB7nPqSELwmfwgOt8U_rK15sHWuGeLhsWYihRtq9ADC3MZ=HTg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, Mar 11, 2017 at 2:53 AM, Jeff Janes <jeff(dot)janes(at)gmail(dot)com> wrote:
> Should the \password tool in psql inspect password_encryption and act on it
> being 'scram'?

Not sure if it is wise to change the default fot this release.

> I didn't see this issue discussed, but the ability to search the archives
> for backslashes is rather limited.

I'll save you some time: it has not been discussed. Nor has
PQencryptPassword been mentioned. Changing to SCRAM is not that
complicated, just call scram_build_verifier() and you are good to go.

Instead of changing the default, I think that we should take this
occasion to rename PQencryptPassword to something like
PQhashPassword(), and extend it with a method argument to support both
md5 and scram. PQencryptPassword could also be marked as deprecated,
or let as-is for some time. For \password, we could have another
meta-command but that sounds grotty, or just extend \password with a
--method argument. Switching the default could happen in another
release.

A patch among those lines would be a simple, do people feel that this
should be part of PG 10?
--
Michael

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2017-03-10 22:51:55 Re: Should we eliminate or reduce HUP from docs?
Previous Message David G. Johnston 2017-03-10 22:42:08 Re: Should we eliminate or reduce HUP from docs?