[Dovecot] SSHA512 auth not working

Noel Butler noel.butler at ausics.net
Tue Apr 16 08:55:10 EEST 2013


On Tue, 2013-04-16 at 03:54 +0200, Marcin Czupryniak wrote:

> I'm trying to configure SSHA512 passwords and when testing discovered 
> that they were not working as expected.
> At first i was using Centos 6.4 which doesn't have the glibc CRYPT 
> newest functions ($6$salt$pass) so had to rollback to the Dovecot format 
> ({SSHA512.HEX}saltedpassword+salt ) but I'm unable to let dovecot 
> authenticate properly.
> 


I have one CentOS server (5.9) and only one, so can't test any others
(they are all slackware)
but... 


            crypt($pass, '$6$' . $salt)


"dino",  results in:

 $6$n.vM3bqg3C6LPtJv
$keF2z/6VXv99NKf92Abbz/sPLBcWHV2hBXOkDf41OKLqe9p7V39xcFc92K1S4WvWQ3rK0konAw.pV.YEQspuM.

So if 6.4 does not work, you are missing something.

try this 
#!/path/to/perl
$pass ="dino";
@pschars = ("A" .. "Z", "a" .. "z", 0 .. 9, ".", "/");
$salt=  join '', @pschars[map {rand @pschars} (1..16)];
$sha512p = crypt($pass, '$6$' . $salt);
print "\n $sha512p \n";



-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: This is a digitally signed message part
URL: <http://dovecot.org/pipermail/dovecot/attachments/20130416/68f865e9/attachment.bin>


More information about the dovecot mailing list