2003-04-28 Marcus Brinkmann <marcus@g10code.de>

* context.h: Remove OPDATA_VERIFY_COLLECTING.
	(struct gpgme_context_s): Remove member notation.
	* gpgme.h: Make enum for GPGME_KEYLIST_MODE_* values.
This commit is contained in:
Marcus Brinkmann 2003-04-29 00:54:11 +00:00
parent 30cdf13284
commit 1ab9b4616a
3 changed files with 30 additions and 19 deletions

View File

@ -1,5 +1,9 @@
2003-04-28 Marcus Brinkmann <marcus@g10code.de> 2003-04-28 Marcus Brinkmann <marcus@g10code.de>
* context.h: Remove OPDATA_VERIFY_COLLECTING.
(struct gpgme_context_s): Remove member notation.
* gpgme.h: Make enum for GPGME_KEYLIST_MODE_* values.
* gpgme.h (struct _gpgme_sig_notation): New structure. * gpgme.h (struct _gpgme_sig_notation): New structure.
(GpgmeSigNotation): New type. (GpgmeSigNotation): New type.
(struct _gpgme_signature): New structure. (struct _gpgme_signature): New structure.

View File

@ -1,4 +1,4 @@
/* context.h /* context.h - Definitions for a GPGME context.
Copyright (C) 2000 Werner Koch (dd9jn) Copyright (C) 2000 Werner Koch (dd9jn)
Copyright (C) 2001, 2002, 2003 g10 Code GmbH Copyright (C) 2001, 2002, 2003 g10 Code GmbH
@ -34,7 +34,7 @@ typedef enum
{ {
OPDATA_DECRYPT, OPDATA_SIGN, OPDATA_ENCRYPT, OPDATA_PASSPHRASE, OPDATA_DECRYPT, OPDATA_SIGN, OPDATA_ENCRYPT, OPDATA_PASSPHRASE,
OPDATA_IMPORT, OPDATA_GENKEY, OPDATA_KEYLIST, OPDATA_EDIT, OPDATA_IMPORT, OPDATA_GENKEY, OPDATA_KEYLIST, OPDATA_EDIT,
OPDATA_VERIFY_COLLECTING, OPDATA_VERIFY OPDATA_VERIFY, OPDATA_TRUSTLIST
} ctx_op_data_type; } ctx_op_data_type;
struct ctx_op_data struct ctx_op_data
@ -102,8 +102,6 @@ struct gpgme_context_s
/* The operation data hooked into the context. */ /* The operation data hooked into the context. */
struct ctx_op_data *op_data; struct ctx_op_data *op_data;
/* Last signature notation. */
GpgmeData notation;
/* Last operation info. */ /* Last operation info. */
GpgmeData op_info; GpgmeData op_info;

View File

@ -21,7 +21,9 @@
#ifndef GPGME_H #ifndef GPGME_H
#define GPGME_H #define GPGME_H
#include <stdio.h> /* For FILE *. */ /* Include stdio.h for the FILE type definition. */
#include <stdio.h>
#ifdef _MSC_VER #ifdef _MSC_VER
typedef long off_t; typedef long off_t;
typedef long ssize_t; typedef long ssize_t;
@ -36,7 +38,7 @@ extern "C" {
#endif #endif
#endif #endif
/* The version of this header should match the one of the library. Do /* The version of this header should match the one of the library. Do
not use this symbol in your application, use gpgme_check_version not use this symbol in your application, use gpgme_check_version
instead. The purpose of this macro is to let autoconf (using the instead. The purpose of this macro is to let autoconf (using the
@ -45,15 +47,15 @@ extern "C" {
that for you! */ that for you! */
#define GPGME_VERSION "0.4.1" #define GPGME_VERSION "0.4.1"
/* The opaque data types used by GPGME. */ /* The opaque data types used by GPGME. */
/* The context holds some global state and configration options as /* The context holds some global state and configration options, as
well as the results of a crypto operation. */ well as the results of a crypto operation. */
struct gpgme_context_s; struct gpgme_context_s;
typedef struct gpgme_context_s *GpgmeCtx; typedef struct gpgme_context_s *GpgmeCtx;
/* The data object used by GPGME to exchange arbitrary data. */ /* The data object is used by GPGME to exchange arbitrary data. */
struct gpgme_data_s; struct gpgme_data_s;
typedef struct gpgme_data_s *GpgmeData; typedef struct gpgme_data_s *GpgmeData;
@ -128,10 +130,11 @@ GpgmeError;
#define GPGME_Invalid_Recipient GPGME_Invalid_UserID #define GPGME_Invalid_Recipient GPGME_Invalid_UserID
#define GPGME_No_Passphrase GPGME_Bad_Passphrase #define GPGME_No_Passphrase GPGME_Bad_Passphrase
/* The possible encoding mode of GpgmeData objects. */ /* The possible encoding mode of GpgmeData objects. */
typedef enum typedef enum
{ {
GPGME_DATA_ENCODING_NONE = 0, /* I.e. not specified. */ GPGME_DATA_ENCODING_NONE = 0, /* Not specified. */
GPGME_DATA_ENCODING_BINARY = 1, GPGME_DATA_ENCODING_BINARY = 1,
GPGME_DATA_ENCODING_BASE64 = 2, GPGME_DATA_ENCODING_BASE64 = 2,
GPGME_DATA_ENCODING_ARMOR = 3 /* Either PEM or OpenPGP Armor. */ GPGME_DATA_ENCODING_ARMOR = 3 /* Either PEM or OpenPGP Armor. */
@ -197,6 +200,7 @@ typedef enum
} }
GpgmeSigMode; GpgmeSigMode;
/* The available key and signature attributes. */ /* The available key and signature attributes. */
typedef enum typedef enum
{ {
@ -247,6 +251,7 @@ typedef enum
} }
GpgmeValidity; GpgmeValidity;
/* The available protocols. */ /* The available protocols. */
typedef enum typedef enum
{ {
@ -342,11 +347,6 @@ typedef enum
} }
GpgmeStatusCode; GpgmeStatusCode;
/* The available keylist mode flags. */
#define GPGME_KEYLIST_MODE_LOCAL 1
#define GPGME_KEYLIST_MODE_EXTERN 2
#define GPGME_KEYLIST_MODE_SIGS 4
/* The engine information structure. */ /* The engine information structure. */
struct _gpgme_engine_info struct _gpgme_engine_info
{ {
@ -381,6 +381,7 @@ typedef void (*GpgmeProgressCb) (void *opaque, const char *what,
typedef GpgmeError (*GpgmeEditCb) (void *opaque, GpgmeStatusCode status, typedef GpgmeError (*GpgmeEditCb) (void *opaque, GpgmeStatusCode status,
const char *args, const char **reply); const char *args, const char **reply);
/* Context management functions. */ /* Context management functions. */
/* Create a new context and return it in CTX. */ /* Create a new context and return it in CTX. */
@ -416,6 +417,14 @@ void gpgme_set_include_certs (GpgmeCtx ctx, int nr_of_certs);
/* Return the number of certs to include in an S/MIME message. */ /* Return the number of certs to include in an S/MIME message. */
int gpgme_get_include_certs (GpgmeCtx ctx); int gpgme_get_include_certs (GpgmeCtx ctx);
/* The available keylist mode flags. */
enum
{
GPGME_KEYLIST_MODE_LOCAL = 1,
GPGME_KEYLIST_MODE_EXTERN = 2,
GPGME_KEYLIST_MODE_SIGS = 4
};
/* Set keylist mode in CTX to MODE. */ /* Set keylist mode in CTX to MODE. */
GpgmeError gpgme_set_keylist_mode (GpgmeCtx ctx, int mode); GpgmeError gpgme_set_keylist_mode (GpgmeCtx ctx, int mode);
@ -534,7 +543,7 @@ void gpgme_get_io_cbs (GpgmeCtx ctx, struct GpgmeIOCbs *io_cbs);
the pending operation to finish. */ the pending operation to finish. */
GpgmeCtx gpgme_wait (GpgmeCtx ctx, GpgmeError *status, int hang); GpgmeCtx gpgme_wait (GpgmeCtx ctx, GpgmeError *status, int hang);
/* Functions to handle recipients. */ /* Functions to handle recipients. */
/* Create a new recipients set and return it in R_RSET. */ /* Create a new recipients set and return it in R_RSET. */
@ -568,7 +577,7 @@ const char *gpgme_recipients_enum_read (const GpgmeRecipients rset,
GpgmeError gpgme_recipients_enum_close (const GpgmeRecipients rset, GpgmeError gpgme_recipients_enum_close (const GpgmeRecipients rset,
void **iter); void **iter);
/* Functions to handle data objects. */ /* Functions to handle data objects. */
/* Read up to SIZE bytes into buffer BUFFER from the data object with /* Read up to SIZE bytes into buffer BUFFER from the data object with
@ -672,7 +681,7 @@ GpgmeError gpgme_data_new_from_filepart (GpgmeData *r_dh,
gpgme_data_seek instead. */ gpgme_data_seek instead. */
GpgmeError gpgme_data_rewind (GpgmeData dh); GpgmeError gpgme_data_rewind (GpgmeData dh);
/* Key and trust functions. */ /* Key and trust functions. */
/* Get the key with the fingerprint FPR from the key cache or from the /* Get the key with the fingerprint FPR from the key cache or from the
@ -1097,7 +1106,7 @@ GpgmeError gpgme_get_engine_info (GpgmeEngineInfo *engine_info);
/* Return a string describing ERR. */ /* Return a string describing ERR. */
const char *gpgme_strerror (GpgmeError err); const char *gpgme_strerror (GpgmeError err);
/* Engine support functions. */ /* Engine support functions. */
/* Verify that the engine implementing PROTO is installed and /* Verify that the engine implementing PROTO is installed and