|
| AI_SignVerify |
|
|
|
|
|
|
Argument | Values | Comments |
|
|
|
|
|
|
formatMethodName | formatX931 | Signature is output as the binary |
|
| concatenation of r with s. |
|
|
|
| formatX931PKCS | Signature is output in PKCS #1 style DER |
|
| encoding. |
|
|
|
| formatX931X957 | Signature is output in X9.57 (DSA) DER |
|
| format. |
|
|
|
formatParams | Pointer to | Use with rsaSignX931 and rsaVerifyX931. |
| structure of |
|
| type A_X931_PARAMS |
|
|
|
|
If formatMethodName is “formatX931”, formatParams must be given a pointer to a structure of type A_X931_PARAMS:
typedef struct { unsigned int blockLen; unsigned int oidNum;
ITEM OID;
}A_X931_PARAMS;
Set the arguments for A_X931_PARAMS as follows:
Argument | Values | Comments |
|
|
|
|
|
|
blockLen | Number of bytes in | This is the number of bytes that the binary |
| final X.931 | concatenation of r with s requires. |
| signature |
|
|
|
|
oidNum | The object | Currently always equals 3 (SHA) for X9.31. |
| identifier for the |
|
| SHA1 hash |
|
| algorithm |
|
|
|
|
OID | Object identifier | Currently only used when |
| to use for BER | “formatX931PKCS” is specified in the |
| encoding | formatMethodName. |
|
| PKCS #1 style BER/DER encoding is used. |
|
|
|
Format of info returned by B_GetAlgorithmInfo:
a pointer to a B_SIGN_VERIFY_PARAMS structure (see above).
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 | 237 |