| 1 |
# This file is read by expand-selected-hashes and gen-crypt-hashes-h. |
| 2 |
# It lists, for each supported hash algorithm, the name to be used to |
| 3 |
# enable or disable it at configure time, which is also part of the |
| 4 |
# name used for the 'crypt_fn' and 'gensalt_fn' entry points to the |
| 5 |
# relevant algorithm module; the prefix used to identify the algorithm |
| 6 |
# in hash strings; the number of bytes of random data that |
| 7 |
# crypt_gensalt should draw from the OS when its caller doesn't supply |
| 8 |
# any; and a comma-separated list of flags. |
| 9 |
# |
| 10 |
# The current set of possible flags is: STRONG means the hash is still |
| 11 |
# considered strong enough to use for newly hashed passwords; this is |
| 12 |
# the set of hashes that will be enabled when the library is |
| 13 |
# configured with --enable-hashes=strong. DEFAULT means that this |
| 14 |
# hash may be used as the default for newly hashed passwords; |
| 15 |
# when crypt_gensalt is called with a null pointer for its prefix |
| 16 |
# argument, it will use the first hash in this file that was enabled |
| 17 |
# and has a DEFAULT flag. Hashes that are not STRONG should never be |
| 18 |
# marked DEFAULT. If you change the set of DEFAULT hashes you must also |
| 19 |
# update test-gensalt.c to match. |
| 20 |
# |
| 21 |
# ALT, FREEBSD, GLIBC, NETBSD, OPENBSD, OSX, OWL, SOLARIS, and SUSE |
| 22 |
# mean that the hash was historically supported by crypt() as provided |
| 23 |
# by that operating system / C library. These are also recognized by |
| 24 |
# --enable-hashes as sets of hashes that can be enabled. |
| 25 |
# |
| 26 |
# Fields are separated by whitespace. Lines beginning with # are |
| 27 |
# ignored; # is not otherwise significant. Multiple flags are |
| 28 |
# separated by commas. A field whose contents are a single colon (:) |
| 29 |
# is actually understood as an empty string; colon is used for this |
| 30 |
# purpose because it cannot be part of a hash prefix or a C identifier. |
| 31 |
# |
| 32 |
# Because the first DEFAULT entry that's enabled is used for new |
| 33 |
# hashes when crypt_gensalt() is called with a null prefix, the list |
| 34 |
# should be kept in decreasing order of cryptographic strength overall |
| 35 |
# (this only *matters* for DEFAULT entries, but it's easier to keep |
| 36 |
# the whole list sorted that way). Because of how crypt() checks |
| 37 |
# prefixes, the hashes that use an empty prefix (bigcrypt and |
| 38 |
# descrypt) must be last (conveniently, these are also the weakest |
| 39 |
# supported hashes). |
| 40 |
# |
| 41 |
#name h_prefix nrbytes flags |
| 42 |
yescrypt $y$ 16 STRONG,DEFAULT,ALT,DEBIAN,FEDORA |
| 43 |
gost_yescrypt $gy$ 16 STRONG,ALT |
| 44 |
sm3_yescrypt $sm3y$ 16 STRONG,EULER,KYLIN |
| 45 |
scrypt $7$ 16 STRONG |
| 46 |
bcrypt $2b$ 16 STRONG,DEFAULT,ALT,FREEBSD,NETBSD,OPENBSD,OWL,SOLARIS,SUSE |
| 47 |
bcrypt_y $2y$ 16 STRONG,ALT,OWL,SUSE |
| 48 |
bcrypt_a $2a$ 16 STRONG,ALT,FREEBSD,NETBSD,OPENBSD,OWL,SOLARIS,SUSE |
| 49 |
bcrypt_x $2x$ 16 ALT,OWL,SUSE |
| 50 |
sm3crypt $sm3$ 16 EULER,KYLIN |
| 51 |
sha512crypt $6$ 15 STRONG,DEFAULT,GLIBC,FREEBSD,SOLARIS |
| 52 |
sha256crypt $5$ 15 GLIBC,FREEBSD,SOLARIS |
| 53 |
sha1crypt $sha1 20 NETBSD |
| 54 |
sunmd5 $md5 8 SOLARIS |
| 55 |
md5crypt $1$ 9 GLIBC,FREEBSD,NETBSD,OPENBSD,SOLARIS |
| 56 |
nt $3$ 1 FREEBSD |
| 57 |
bsdicrypt _ 3 FREEBSD,NETBSD,OPENBSD,OSX |
| 58 |
bigcrypt : 2 : |
| 59 |
descrypt : 2 GLIBC,FREEBSD,NETBSD,OPENBSD,SOLARIS,OSX |