GNU Info

Info Node: (gpgme.info)Creating a Signature

(gpgme.info)Creating a Signature


Prev: Selecting Signers Up: Sign
Enter node , (file) or (file)node

Creating a Signature
....................

 - Data type: enum GpgmeSigMode
     The `GpgmeSigMode' type is used to specify the desired type of a
     signature.  The following modes are available:

    `GPGME_SIG_MODE_NORMAL'
          A normal signature is made, the output includes the plaintext
          and the signature.

    `GPGME_SIG_MODE_DETACH'
          A detached signature is made.

    `GPGME_SIG_MODE_CLEAR'
          A clear text signature is made.  The ASCII armor and text
          mode settings of the context are ignored.

 - Function: GpgmeError gpgme_op_sign (GpgmeCtx CTX, GpgmeData PLAIN,
          GpgmeData SIG, GpgmeSigMode MODE)
     The function `gpgme_op_sign' creates a signature for the text in
     the data object PLAIN and returns it in the data object SIG.  The
     type of the signature created is determined by the ASCII armor and
     text mode attributes set for the context CTX and the requested
     signature mode MODE.

     More information about the signatures is available with
     `gpgme_get_op_info'.  Note: Detailed Results.

     If an S/MIME signed message is created using the CMS crypto engine,
     the number of certificates to include in the message can be
     specified with `gpgme_set_include_certs'.  Note: Included
     Certificates.

     The function returns `GPGME_No_Error' if the signature could be
     created successfully, `GPGME_Invalid_Value' if CTX, PLAIN or SIG
     is not a valid pointer, `GPGME_No_Data' if the signature could not
     be created, `GPGME_No_Passphrase' if the passphrase for the secret
     key could not be retrieved, and passes through any errors that are
     reported by the crypto engine support routines.

 - Function: GpgmeError gpgme_op_sign (GpgmeCtx CTX, GpgmeData PLAIN,
          GpgmeData SIG, GpgmeSigMode MODE)
     The function `gpgme_op_sign_start' initiates a `gpgme_op_sign'
     operation.  It can be completed by calling `gpgme_wait' on the
     context.  Note: Waiting For Completion.

     The function returns `GPGME_No_Error' if the operation could be
     started successfully, and `GPGME_Invalid_Value' if CTX, PLAIN or
     SIG is not a valid pointer.


automatically generated by info2www version 1.2.2.9