0
8.9kviews
Secure Hash Algorithm (SHA)
1 Answer
4
716views

Secure flash algorithm (SHA)

  • Most widely used flash function

  • Produces 160 bit hash values

  • It it based on MD5

  • The input is a message with length equal to $\lt 2^{64} bits$

  • The output is a message digest of length 160 bit

  • The processing is done of 572 bit blocks

Steps

  • Step1: append padding bits Message is padded with a 1 and as many 0’s as necessary to bring the message length to 64 bits fewer/ less than an even multiple of 512.

  • Step2: Append the length 54 bits are appended to the end of the padded message. These bits hold the binary format of 64 bits indicating the length of the original message.

  • Step3: Initialize MD buffer

    • 160 but buffer is used to hard the intermediate and final results.

    • The buffer is represented as 5-32 bit registers A,B,C,D,E

    • They are initialized as :

<strong>diagram</strong>

  • Step 4: Process the message in 572 bit word blocks

    • The number of rounds = 4

    • Each round has 20 steps

    • Four different logical functions $f_1, f_2, f_3, f_4$

    • Each round make use of additive constant $K_t$ where $0 \ltt\lt79$

    • Four different are used

    • The output of the 80^th round is added to the input to the 1^st round to produce the output

  • Step 5: Output

    • After all 512 bit block is processed, the output from the I^th stage is 160 bit message digest

<strong>diagram</strong>

Please log in to add an answer.