Next: , Previous: Working with IO objects, Up: AC Interface


6.6.4 Working with handles

In order to use an algorithm, an according handle must be created. This is done using the following function:

— Function: gcry_error_t gcry_ac_open (gcry_ac_handle_t *handle, int algorithm, int flags)

Creates a new handle for the algorithm algorithm and stores it in handle. flags is not used currently.

algorithm must be a valid algorithm ID, see See Available asymmetric algorithms, for a list of supported algorithms and the according constants. Besides using the listed constants directly, the functions gcry_pk_name_to_id may be used to convert the textual name of an algorithm into the according numeric ID.

— Function: void gcry_ac_close (gcry_ac_handle_t handle)

Destroys the handle handle.