Next: , Up: Sign   [Contents][Index]


7.6.4.1 Selecting Signers

The key or the keys used to create a signature are stored in the context. The following functions can be used to manipulate this list. If no signer has been set into the context a default key is used for signing.

Function: void gpgme_signers_clear (gpgme_ctx_t ctx)

The function gpgme_signers_clear releases a reference for each key on the signers list and removes the list of signers from the context ctx.

Every context starts with an empty list.

Function: gpgme_error_t gpgme_signers_add (gpgme_ctx_t ctx, const gpgme_key_t key)

The function gpgme_signers_add adds the key key to the list of signers in the context ctx.

Calling this function acquires an additional reference for the key.

Function: unsigned int gpgme_signers_count (const gpgme_ctx_t ctx)

SINCE: 1.4.3

The function gpgme_signers_count returns the number of signer keys in the context ctx.

Function: gpgme_key_t gpgme_signers_enum (const gpgme_ctx_t ctx, int seq)

The function gpgme_signers_enum returns the seqth key in the list of signers in the context ctx. An additional reference is acquired for the user.

If seq is out of range, NULL is returned.