Re: Maximum password length

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: Alexander Kukushkin <cyberdemn(at)gmail(dot)com>, bossartn(at)amazon(dot)com, Stephen Frost <sfrost(at)snowman(dot)net>, isaac(dot)morland(at)gmail(dot)com, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Maximum password length
Date: 2020-09-02 00:58:23
Message-ID: 278665.1599008303@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I wrote:
> Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> writes:
>> ISTM that it's only going to be a matter of time before that will be
>> exceeded. Why have a limit at all? Accept whatever StringInfo accepts.

> Hmm, that would require some refactoring of simple_prompt for starters.

To use StringInfo, we have to move sprompt.c into src/common/ where
the stringinfo stuff lives; but that seems fine to me, because it had
little if any business being in src/port/. Here's a draft patch
that does it that way.

This could be refined; in particular, I think that most of the
password-prompting sites could drop their separate have_password
flags in favor of checking whether the password pointer is NULL
or not. That would likely also prove that some of the free(password)
calls I sprinkled in are unnecessary.

regards, tom lane

Attachment Content-Type Size
remove-password-length-limits-1.patch text/x-diff 24.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2020-09-02 01:00:12 Re: Allow CLUSTER, VACUUM FULL and REINDEX to change tablespace on the fly
Previous Message Alvaro Herrera 2020-09-02 00:49:41 Re: Dependencies for partitioned indexes are still a mess