ippsHashDRBG_GenBN#
Generates a pseudorandom positive Big Number of the specified bit length.
Syntax#
IppStatus ippsHashDRBG_GenBN(IppsBigNumState* pRand,
int nBits,
const int requestedSecurityStrength,
const int predictionResistanceRequest,
const Ipp8u* addlInput,
const int addlInputBitsLen,
IppsHashDRBG_EntropyInputCtx* pEntrInputCtx,
IppsHashDRBGState* pDrbgCtx);
Include Files#
ippcp.h
Parameters#
pRand |
Pointer to the output pseudorandom Big Number. |
nBits |
Requested number of bits to be generated. |
requestedSecurityStrength |
The security strength to be associated with the requested pseudorandom bits. |
predictionResistanceRequest |
Indicates whether or not prediction resistance is to be provided during the request (whether or not fresh entropy bits are required). |
addlInput |
Pointer to the array containing additional input (optional). |
addlInputBitsLen |
Length of the |
pEntrInputCtx |
Pointer to the Entropy input context.
The size is equal to the value returned by |
pDrbgCtx |
Pointer to the |
Description#
The ippsHashDRBG_GenBN function:
Calls the reseed function to incorporate fresh entropy when prediction resistance is requested or the Hash DRBG has reached the end of its reseed interval.
Generates a pseudorandom Big Number of the specified
nBitslength and updates the working state.
Return Values#
ippStsNoErr |
Indicates no error. All single operations executed without errors. Any other value indicates an error. |
ippStsNullPtrErr |
|
ippStsContextMatchErr |
If the Big Number identifier doesn’t match. If the Hash DRBG identifier doesn’t match. If the Entropy input context identifier doesn’t match. |
ippStsBadArgErr |
Prediction resistance is requested but |
ippStsOutOfRangeErr |
The length of |
ippStsNotSupportedModeErr |
The CPU does not support the |
ippStsHashOperationErr |
An error status code was returned during hashing operations. |