The value of the hexadecimal numbers specified in RFC 3174 (SHA-1)

I'm trying to learn about SHA-1, I was looking at the C implementation that was included in the specification (RFC 31741), and this part confuses me:

context->Intermediate_Hash[0]   = 0x67452301;
context->Intermediate_Hash[1]   = 0xEFCDAB89;
context->Intermediate_Hash[2]   = 0x98BADCFE;
context->Intermediate_Hash[3]   = 0x10325476;
context->Intermediate_Hash[4]   = 0xC3D2E1F0;

What is the meaning of these hard-coded hexadecimal values, are they just a special sauce that makes the algorithm work, or are some mathematical constants?

You can view the full code here: http://www.faqs.org/rfcs/rfc3174.html

+3
source share
3 answers

They are "nothing with my sleeves . "

. , , . , , - , , .

pi SHA-1 :

: k 2 ^ 30 2, 3, 5 10. h0-h3 MD5, ( h4) .

: SHA-1

+1

, , . . Carmack Square Root. , .

, , , . O - , , .

+1

, , SHA-1 ( RFC) FIPS 180. , , , : - (

, SHA-1 .

+1

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


All Articles