MD5 vs. SHA1: hashed passwords in /etc/master.passwd - can we configure SHA1 as default in /etc/login.conf?

O. Hartmann ohartman at mail.zedat.fu-berlin.de
Sat Jan 3 14:13:07 PST 2009


MD5 seems to be compromised by potential collision attacks. So I tried
to figure out how I can use another hash for security purposes when
hashing passwords for local users on a FreeBSD 7/8 box, like root or
local box administration. Looking at man login.conf reveals only three
possible hash algorithms selectable: md5 (recommended), des and blf.
Changing /etc/login.conf's tag

default:\
        :passwd_format=sha1:\


followed by a obligatory "cap_mkdb" seems to do something - changing
root's password results in different hashes when selecting different
hash algorithms like des, md5, sha1, blf or even sha256.

Well, I never digged deep enough into the source code to reveal the
magic and truth, so I will ask here for some help. Is it possible to
change the md5-algorithm by default towards sha1 as recommended after
the md5-collisions has been published?

Thanks in advance,
Oliver

-------------- next part --------------
An embedded message was scrubbed...
From: "O. Hartmann" <ohartman at mail.zedat.fu-berlin.de>
Subject: MD5 vs. SHA1 hashed passwords in /etc/master.passwd: can we configure
	SHA1 in /etc/login.conf?
Date: Sat, 03 Jan 2009 22:45:59 +0100
Size: 1386
Url: http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20090103/ac98096d/AttachedMessage.eml


More information about the freebsd-questions mailing list