What does $ 4 $ mean in sha1pass output?

When creating a password with the sha1passfirst value from the token is "4".

For instance:

sha1pass test

gives us:

$4$GTdnmykS$25iwV+ruXRwor4pUmKF57uXHj70$

The token uses as separators $: 25iwV+ruXRwor4pUmKF57uXHj70- this is a calculated hash, GTdnmykS- this is the generated salt, since I did not give the second parameter, but what does << 26> mean?

4 is really hard-coded, this is the last line sha1pass, which is a Perl script:

print '$4$', $salt, '$', $pass, "\$\n";

Why is the first value of this token “4”, and what does it mean?

+3
source share
3 answers

, , $1 $ MD5 $4 $ SHA1. , , .

+6

, , , SHA-1; $1$ MD5, $5$ SHA-2-256 $6$ SHA-2-512.

+8

, , -, .

, ? , unix, crypt (Unix):

$digit $, . , .

+3

Source: https://habr.com/ru/post/1766121/


All Articles