AI_DHParamGen
AI_DHParamGen
Purpose:
This AI allows you to generate
Type of information this allows you to use:
the parameters for generating
Format of info supplied to B_SetAlgorithmInfo:
pointer to an A_DH_PARAM_GEN_PARAMS structure:
typedef struct | { |
|
|
|
unsigned int | primeBits; | /* size of prime modulus in | bits | */ |
unsigned int | exponentBits; | /* size of random exponent in | bits | */ |
}A_DH_PARAM_GEN_PARAMS;
The exponentBits must be less than primeBits.
Format of info returned by B_GetAlgorithmInfo:
pointer to an A_DH_PARAM_GEN_PARAMS structure (see above).
Crypto-C procedures to use with algorithm object:
B_GenerateInit and B_GenerateParameters. B_GenerateParameters sets the resultAlgorithmObject with the AI_DHKeyAgree information. You must pass an initialized random algorithm to B_GenerateParameters.
Algorithm methods to include in application’s algorithm chooser:
AM_DH_PARAM_GEN.
C h a p t e r 2 A l g o r i t h m I n f o Ty p e s | 49 |