Your Browser is not longer supported

Please use Google Chrome, Mozilla Firefox or Microsoft Edge to view the page correctly
Loading...

{{viewport.spaceProperty.prod}}

CGENRAL - general functions

&pagelevel(4)&pagelevel

The CGENRAL macro covers all of the following general functions:

  • initializing a Cryptoki library

  • finalizing an application with the Cryptoki library

  • outputting general information about Cryptoki

  • outputting the function list of the Cryptoki library

All functions are always performed synchronously

A detailed description of the functions of the CGENRAL macro can be found in PKCS#11 V2.20: Cryptographic Token Interface Standard in section 11.4 “General-purpose functions”.

Macro

Operands

CGENRAL

MF=C / D / L / M / E

,VERSION=001 / 002

,ACTION= *INITIALIZE / *FINALIZE / *GETINFO / *GETFUNCTIONLIST /

<var: enum-of _action_set: 1> / default: _action_set.undefined

,EXEC=*SYNCHRON / *ASYNCHRON / <var: enum-of _exec_set:1> /

default: _exec_set.synchron

,INFO=<var: pointer> / NULL

,BOID=<var: int:4> / 0

,RPOSTAD=<var: pointer> / NULL

,RPOSTL=<integer 1..2> / <var: int:4> / 0

VERSION

specifies which version of the parameter area is to be generated. It is always advisable to use the latest version.

=001

This generates the format that was supported by CRYPT V1.0. This format only supports the parameters already known in CRYPT V1.0.
VERSION=001 is the default.

=002

This generates the format that is supported as of CRYPT V1.1.

 

ACTION

Type of action.
The corresponding PKCS#11 function is specified for each action code.

=*INITIALIZE

corresponds to the PKCS#11 function C_Initialize;
initializes the Cryptoki library.

=*FINALIZE

corresponds to the PKCS#11 function C_Finalize;
indicates that an application has been executed with the Cryptoki library.

=*GETINFO

corresponds to the PKCS#11 function C_GetInfo;
outputs general information about Cryptoki.

=*GETFUNCTIONLIST

corresponds to the PKCS#11 function C_GetFunctionList;
outputs the function list.
This function is not supported.

EXEC

specifies the execution mode of the following functions

=*SYNCHRONOUS

only restores control to the caller once the function has been executed.

=*ASYNCHRONOUS

restores control to the caller once the function has been sent to the token.

INFO

Type of information output depending on the action:

  • *INITIALIZE: INFO points to an _INITIALIZE_ARGS structure

  • *FINALIZE: INFO should be set to NULL_PTR.

  • *GETINFO: INFO points tothe storage area which will receive the information.

  • *GETFUNCTIONLIST: INFO points to a value which receives a pointer to the _FUNCTION_LIST structure of the library.

BOID

Event identification

  • in the case of synchronous execution: BOID is not used

  • in the case of asynchronous execution: event identification which informs the program about the scheduling of CRYPT.

RPOSTAD

Address of postcode

  • in the case of synchronous execution: RPOSTAD is not used.

  • in the case of asynchronous execution: specifies a field containing the postcode information which is to be transferred to the corresponding program that issues the SOLSIG call (see also “Executive Macros” user guide [3]).
    Length of postcode: 4 or 8 bytes

RPOSTL

Length of postcode

  • in the case of synchronous execution: RPOSTL is not used.

  • in the case of asynchronous execution: specifies the length of the postcode information in words (1 or 2).