plugins/postfixadmin-change-password: Add "ARGON2I"

My mail server was set up with `dovecot:ARGON2I` password encryption option.  This allows people who set up argon2i as the encryption method to continue using it when users change their password with the plugin.
This commit is contained in:
Simon Chuu 2020-05-18 22:59:05 -04:00 committed by GitHub
parent ad9d153d76
commit 3dbb43e188
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -319,6 +319,10 @@ class ChangePasswordPostfixAdminDriver implements \RainLoop\Providers\ChangePass
case 'sha512-crypt':
$sResult = '{SHA512-CRYPT}' . crypt($sPassword,'$6$'.$sSalt);
break;
case 'argon2i':
$sResult = '{ARGON2I}' . password_hash($sPassword, PASSWORD_ARGON2I);
break;
case 'mysql_encrypt':
if($this->sEngine == 'MySQL'){