Re: Should rolpassword be toastable? - Mailing list pgsql-hackers

From Nathan Bossart
Subject Re: Should rolpassword be toastable?
Date
Msg-id ZuxjAIOJ4GSa34KC@nathan
Whole thread Raw
In response to Re: Should rolpassword be toastable?  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Thu, Sep 19, 2024 at 10:31:15AM -0400, Tom Lane wrote:
> Nathan Bossart <nathandbossart@gmail.com> writes:
>> Hm.  It does seem like there's little point in giving pg_authid a TOAST
>> table, as rolpassword is the only varlena column, and it obviously has
>> problems.  But wouldn't removing it just trade one unhelpful internal error
>> when trying to log in for another when trying to add a really long password
>> hash (which hopefully nobody is really trying to do in practice)?  I wonder
>> if we could make this a little more user-friendly.
> 
> We could put an arbitrary limit (say, half of BLCKSZ) on the length of
> passwords.

Something like that could be good enough.  I was thinking about actually
validating that the hash had the correct form, but that might be a little
more complex than is warranted here.

-- 
nathan



pgsql-hackers by date:

Previous
From: Masahiko Sawada
Date:
Subject: Re: Pgoutput not capturing the generated columns
Next
From: Masahiko Sawada
Date:
Subject: Re: Conflict detection for update_deleted in logical replication