Cryptography Reference
In-Depth Information
Additionally, in random.h are defined the macros bRandAES_l() , sRandAES_l() ,
and lRandAES_l() , each of which expects an initialized state buffer as argument,
and they generate random numbers of types UCHAR , USHORT ,and ULONG from these
buffers.
The deletion of the generator takes place in analogy to RandBBS with the
following function:
Function:
deletion of the internal state of RandAES
Syntax:
void
PurgeRandAES_1 (STATEAES *rstate);
rstate (internal state of the pseudorandom number generator)
Input:
rstate (internal state of the pseudorandom number generator,
deleted by overwriting)
Ouput:
12.2.4 The RMDSHA-1 Generator
The following pseudorandom number generator will be built from the hash
functions SHA-1 and RIPEMD-160. Both functions can be calculated extremely
quickly, which leads to a generator with excellent performance.
With the definitions D := 0 ,..., 2 160
1 ,C :=
{
0 ,...,c
1
}
,
S := D × C ,and R := 0 ,..., 2 8
1 for input values, counters, states, and
output values, the state function is described by
φ ( x, i ):= RIPEMD-160( x ) ,i +1 mod c ,
φ : S → S,
(12.6)
and the output function determined by
ψ ( x, i ) := SHA-1( x ) / 2 8 · (19 ( i mod 16)) mod 2 8 .
ψ : S → R,
(12.7)
As in the case of RandAES, the output is varied with the help of the counter i
in such a way that in successive steps, varying byte positions are selected as
output values. The initialization of the generator takes place via the function
InitRandRMDSHA1_l() :
 
Search WWH ::




Custom Search