| RSA BSAFE Crypto-C |
Cryptographic Components for C |
| Search |
This AI type is similar to AI_DHKeyAgree except that it uses the ASN.1 BER format.
The OID for this algorithm, excluding the tag and length Bytes, in decimal, is 42, 134, 72, 134, 247, 13, 1, 3, 1.
info Format
| B_SetAlgorithmInfo() | A pointer to ITEM that gives the address and length of the BER-encoded algorithm identifier. The encoding is converted to DER before it is copied to the algorithm object. B_SetAlgorithmInfo() returns BE_WRONG_ALGORITHM_INFO if the AI specifies an algorithm other than Diffie-Hellman. |
| B_GetAlgorithmInfo() | A pointer to ITEM that gives the address and length of the DER-encoded AI. |
AI_DHKeyAgreeBER Information
| Functions to use | B_KeyAgreeInit(), B_KeyAgreePhase1(), B_KeyAgreePhase2(), B_SetAlgorithmState() and B_GetAlgorithmState(). Pass an initialized random algorithm to B_KeyAgreePhase1(). |
| AMs to include | AM_DH_KEY_AGREE. |
| Compatible representation | AI_DHKeyAgree. |
| Output considerations | The size of the output of B_KeyAgreePhase1() (the public value) will be the same size as the prime. The size of the output of B_KeyAgreePhase2() (the agreed-upon secret) will also be the same size as the prime. |