java - How to set MessageDigest seed? -


Text after "div class =" itemprop = "text">

implements the MessageDigest class SHA-1 algorithm (among many others). The SHA-1 algorithm allows anyone to use a different "seed" or initial digest

initializes the algorithm variable, or the seed:

  variable start: H0 = 0x67452301 h1 = 0x 9BADCFE h3 = 0x10325476 h4 = 0xC3D2E1F0   

Although the message ding class, as described, does not provide the API to set these initial variables. In fact, this does not tell the value of the initial variable.

How can I set initial seeds for SHA-1 algorithm?

Where is SHA-1 in Java, an example of using an initial seed ?
(I'm looking for SHA-1 implementation, unless that for example MessageDigest uses an option with the initial seed.)

Where do you see the need for seeds in the SHA-1 digest? Normally the encryption algorithm requires the source of a random number, a seed is "necessary". But in SHA-1 you do not use random numbers at all, so there is no seed or initial vector to set up. The variables you are referring to are 'hard' (constants), they are part of the algorithm, no need or use to change the values ​​of h0-4.


Comments

Popular posts from this blog

Eclipse CDT variable colors in editor -

AJAX doesn't send POST query -

wpf - Custom Message Box Advice -