ippsHashDRBG_Reseed#
Reseeds the Hash DRBG state with new entropy.
Syntax#
IppStatus ippsHashDRBG_Reseed(const int predictionResistanceRequest,
const Ipp8u* addlInput,
const int addlInputBitsLen,
IppsHashDRBG_EntropyInputCtx* pEntrInputCtx,
IppsHashDRBGState* pDrbgCtx);
Include Files#
ippcp.h
Parameters#
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 |
Note
The minimum length of the entropy input shall be equal to or greater than the security strength.
Description#
The reseed function:
Obtains entropy input using the following priority order:
Custom callback: calls
getEntropyInput()if not NULL.Hardware RDSEED: calls
ippsTRNGenRDSEED()if CPU supports RDSEED instruction.Hardware RDRAND: calls
ippsPRNGenRDRAND()if CPU supports RDRAND instruction.
Checks whether the entropy is sufficient to support the security strength.
Using the reseed algorithm, combines the current seed from the state with the new entropy input and any additional input and updates the state.
Return Values#
ippStsNoErr |
Indicates no error. All single operations executed without errors. Any other value indicates an error. |
ippStsNullPtrErr |
|
ippStsContextMatchErr |
If the Hash DRBG identifier doesn’t match. If the Entropy input context identifier doesn’t match. |
ippStsOutOfRangeErr |
The length of the |
ippStsBadArgErr |
Prediction resistance is requested but |
ippStsNotSupportedModeErr |
The CPU supports neither |
ippStsHashOperationErr |
An error status code was returned during hashing operations. |