ippsMLDSA_KeyGen#
Generates public and private keys.
Syntax#
IppStatus ippsMLDSA_KeyGen(Ipp8u* pPubKey,
Ipp8u* pPrvKey,
IppsMLDSAState* pMLDSAState,
Ipp8u* pScratchBuffer,
IppBitSupplier rndFunc,
void* pRndParam);
Include Files#
ippcp.h
Parameters#
pPubKey |
Pointer to the produced public key. |
pPrvKey |
Pointer to the produced private key. |
pMLDSAState |
Pointer to the ML-DSA state. |
pScratchBuffer |
Pointer to the working buffer of size queried ippsMLDSA_KeyGenBufferGetSize. |
rndFunc |
Optional function pointer to generate random numbers, can be |
pRndParam |
Optional parameters for |
Description#
The function generates a public key and a private key. The size of the output parameters depends on the selected scheme type and can be obtained using ippsMLDSA_GetInfo function. The working buffer should be allocated with the size not less than provided by ippsMLDSA_KeyGenBufferGetSize function.
This function internally uses the random number generator (RNG) provided by the user through the rndFunc
parameter, please see User’s Implementation of a RNG
for more information on creating a customer-defined RNG object. If rndFunc is NULL, an internal
default random number generator based on the RDSEED hardware instruction is used.
Return Values#
ippStsNoErr |
Indicates no error. Any other value indicates an error or warning. |
ippStsNullPtrErr |
Any of the input pointers is |
ippStsContextMatchErr |
|
ippStsMemAllocErr |
An internal functional error. If this output status appears, update to the latest version of the library or contact Intel. |
ippStsNotSupportedModeErr |
Unsupported |
ippStsErr |
Random bit sequence can’t be generated. |
An error that may be returned by |
Problems with the user-defined random number generator. |