CryptoSpi::MRandom Class Reference

class CryptoSpi::MRandom : public CryptoSpi::MPlugin

A pseudo-random number generator (PRNG). Generates random numbers derived from entropy obtained from another source, usually a hardware random number generator or if unavailable, from a combination variety of unpredictable system variables, added to an entropy pool which is used for seeding. This might include keypresses generated by a user, hardware interrupts, etc.

Inherits from

Member Functions Documentation

GenerateRandomBytesL(TDes8 &)

void GenerateRandomBytesL ( TDes8 & aDest ) [pure virtual]

Implementations of this method should fill the passed buffer with the generated pseudo-random data up to the current length, discarding any current contents. The implementations should leave with KErrNotSecure when the generated random data is not secure enough.

leave
KErrNotSecure Random data generated is not secure enough for crytographic operations otherwise, leaves with any other system wide error code.

Parameters

TDes8 & aDest The buffer to fill with random data