Re: Maximum password length

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Maximum password length
Дата
Msg-id 143437.1598985384@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Maximum password length  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Maximum password length  ("Bossart, Nathan" <bossartn@amazon.com>)
Список pgsql-hackers
I wrote:
> Note this patch is intended to be applied over my patch at [2],
> since it modifies the test case added there.

I've now pushed that patch, so the patch in my previous mail should
directly apply to HEAD.

I'd originally been wondering whether we need to back-patch this patch.
But unless someone wants to make a case for the max password length
being more than 1024, it seems like this is mostly cleanup and could
just be done in HEAD.  At 1024, the actual behavior of pg_saslprep()
isn't changing at all, and the behavior of recv_password_packet() isn't
changing by much.  The real impact is just that the places that prompt
for a password will accept passwords up to 1K instead of 100 bytes.
Which, TBH, seems like neatnik-ism rather than fixing anything useful.
Surely nobody is going to manually enter passwords exceeding 100 bytes.
And, since simple_prompt insists on reading /dev/tty not stdin, there
is no very easy way to pass a machine-generated password through that
code path.  The practical ways to deal with a long password are either
to set it as PGPASSWORD (has always worked) or put it in .pgpass
(works as of now).

Anyway, I added this thread to the upcoming CF, in case anyone wants to
discuss it further.

            regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: ALTER TABLE .. DETACH PARTITION CONCURRENTLY
Следующее
От: Mark Dilger
Дата:
Сообщение: Re: factorial function/phase out postfix operators?