Debian 12 to 13 upgrade - email auth failures - weak hash

Well, that wasn’t seamless at all.

Migrated from a Debian 12 host to a Debian 13 host (latest version) and upon restoring users many couldn’t login to their emails. After lots of troubleshooting, basically resetting passwords, the following was noted:

Oct 22 15:40:12 auth([email protected],sasl:plain): Error: passwd-file: Invalid password in passdb: Weak password scheme ‘MD5’ used and refused

Our friend Claude says “The account’s password is stored as an MD5 hash, which the old server’s Dovecot accepted. The newer Dovecot on Debian 13 refuses weak hash schemes by default, so it won’t even check the password. Any mailbox whose password was set years ago, on an older Hestia install, will have the same problem.”

To check the accounts with weak hashs run:
sudo sh -c “grep -H ‘{MD5’ /home//conf/mail//passwd” | cut -d: -f1,2

If this output could be included in the installation script it would be very much appreciated !

command got corrupted in your post…

sudo sh -c "grep -H '{MD5' /home/*/conf/mail/*/passwd" | cut -d: -f1,2