71775ad8fc
* README: Refer to COPYING.LESSER and "each file" instead of COPYING. * COPYING.LESSER: New file. * gpgme.spec.in (%doc): Add COPYING.LESSER. * acinclude.m4, configure.ac, Makefile.am: Change license to LGPL 2.1 or later. * TODO: Add copyright notice. * README.CVS: Likewise. assuan/ 2004-12-07 Marcus Brinkmann <marcus@g10code.de> * README.1st: Add copyright notice. doc/ 2004-12-07 Marcus Brinkmann <marcus@g10code.de> * Makefile.am: Change license to LGPL. (gpgme_TEXINFOS): Replace gpl.texi with lesser.texi. * gpgme.texi: Change license to LGPL (also for documentation of GPGME's license). * lesser.texi: New file. * gpl.texi: File removed. gpgme/ 2004-12-07 Marcus Brinkmann <marcus@g10code.de> * putc_unlocked.c, funopen.c: I just claim copyright on these files and change their license to LGPL, because they are totally trivial wrapper functions. * isascii.c: Change copyright notice to the one from ctype/ctype.h in the GNU C Library (CVS Head 2004-10-10), where isascii is defined as a macro doing exactly the same as the function in this file. * memrchr.c: Update from the GNU C Library (CVS Head 2001-07-06). * stpcpy.c: Update from the GNU C Library (CVS Head 2004-10-10). * ath.c, ath-compat.c, ath.h, ath-pth.c, ath-pth-compat.c, ath-pthread.c, ath-pthread-compat.c, context.h, conversion.c, data.c, data-compat.c, data-fd.c, data.h, data-mem.c, data-stream.c, data-user.c, debug.c, debug.h, decrypt.c, decrypt-verify.c, delete.c, edit.c, encrypt.c, encrypt-sign.c, engine-backend.h, engine.c, engine-gpgsm.c, engine.h, error.c, export.c, genkey.c, get-env.c, gpgme.c, gpgme.h, import.c, io.h, key.c, keylist.c, mkstatus, Makefile.am, ops.h, op-support.c, passphrase.c, posix-io.c, posix-sema.c, posix-util.c, progress.c, rungpg.c, sema.h, sign.c, signers.c, trust-item.c, trustlist.c, util.h, verify.c, version.c, w32-io.c, w32-sema.c, w32-util.c, wait.c, wait-global.c, wait.h, wait-private.c, wait-user.c: Change license to LGPL. tests/ 2004-12-07 Marcus Brinkmann <marcus@g10code.de> * gpg/mkdemodirs: Add copyright notice. * gpgsm/Makefile.am, gpgsm/t-support.h, gpgsm/t-decrypt.c, gpgsm/t-encrypt.c, gpgsm/t-export.c, gpgsm/t-genkey.c, gpgsm/t-import.c, gpgsm/t-keylist.c, gpgsm/t-sign.c, gpgsm/t-verify.c, gpg/Makefile.am, gpg/t-decrypt.c, gpg/t-decrypt-verify.c, gpg/t-edit.c, gpg/t-encrypt.c, gpg/t-encrypt-sign.c, gpg/t-encrypt-sym.c, gpg/t-eventloop.c, gpg/t-export.c, gpg/t-genkey.c, gpg/t-import.c, gpg/t-keylist.c, gpg/t-keylist-sig.c, gpg/t-sign.c, gpg/t-signers.c, gpg/t-support.h, gpg/t-thread1.c, gpg/t-trustlist.c, gpg/t-verify.c, Makefile.am, t-data.c, t-engine-info.c, t-version.c: Change license to LGPL.
124 lines
4.5 KiB
C
124 lines
4.5 KiB
C
/* engine.h - GPGME engine interface.
|
|
Copyright (C) 2000 Werner Koch (dd9jn)
|
|
Copyright (C) 2001, 2002, 2003, 2004 g10 Code GmbH
|
|
|
|
This file is part of GPGME.
|
|
|
|
GPGME is free software; you can redistribute it and/or modify it
|
|
under the terms of the GNU Lesser General Public License as
|
|
published by the Free Software Foundation; either version 2.1 of
|
|
the License, or (at your option) any later version.
|
|
|
|
GPGME is distributed in the hope that it will be useful, but
|
|
WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
Lesser General Public License for more details.
|
|
|
|
You should have received a copy of the GNU Lesser General Public
|
|
License along with this program; if not, write to the Free Software
|
|
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
|
|
02111-1307, USA. */
|
|
|
|
#ifndef ENGINE_H
|
|
#define ENGINE_H
|
|
|
|
#include "gpgme.h"
|
|
|
|
struct engine;
|
|
typedef struct engine *engine_t;
|
|
|
|
typedef gpgme_error_t (*engine_status_handler_t) (void *priv,
|
|
gpgme_status_code_t code,
|
|
char *args);
|
|
typedef gpgme_error_t (*engine_colon_line_handler_t) (void *priv, char *line);
|
|
typedef gpgme_error_t (*engine_command_handler_t) (void *priv,
|
|
gpgme_status_code_t code,
|
|
const char *keyword,
|
|
int fd);
|
|
|
|
/* Get a deep copy of the engine info and return it in INFO. */
|
|
gpgme_error_t _gpgme_engine_info_copy (gpgme_engine_info_t *r_info);
|
|
|
|
/* Release the engine info INFO. */
|
|
void _gpgme_engine_info_release (gpgme_engine_info_t info);
|
|
|
|
|
|
gpgme_error_t _gpgme_engine_new (gpgme_engine_info_t info,
|
|
engine_t *r_engine,
|
|
const char *lc_ctype,
|
|
const char *lc_messages);
|
|
void _gpgme_engine_release (engine_t engine);
|
|
void _gpgme_engine_set_status_handler (engine_t engine,
|
|
engine_status_handler_t fnc,
|
|
void *fnc_value);
|
|
gpgme_error_t _gpgme_engine_set_command_handler (engine_t engine,
|
|
engine_command_handler_t fnc,
|
|
void *fnc_value,
|
|
gpgme_data_t data);
|
|
gpgme_error_t
|
|
_gpgme_engine_set_colon_line_handler (engine_t engine,
|
|
engine_colon_line_handler_t fnc,
|
|
void *fnc_value);
|
|
gpgme_error_t _gpgme_engine_op_decrypt (engine_t engine,
|
|
gpgme_data_t ciph,
|
|
gpgme_data_t plain);
|
|
gpgme_error_t _gpgme_engine_op_delete (engine_t engine, gpgme_key_t key,
|
|
int allow_secret);
|
|
gpgme_error_t _gpgme_engine_op_edit (engine_t engine, int type,
|
|
gpgme_key_t key, gpgme_data_t out,
|
|
gpgme_ctx_t ctx /* FIXME */);
|
|
gpgme_error_t _gpgme_engine_op_encrypt (engine_t engine,
|
|
gpgme_key_t recp[],
|
|
gpgme_encrypt_flags_t flags,
|
|
gpgme_data_t plain, gpgme_data_t ciph,
|
|
int use_armor);
|
|
gpgme_error_t _gpgme_engine_op_encrypt_sign (engine_t engine,
|
|
gpgme_key_t recp[],
|
|
gpgme_encrypt_flags_t flags,
|
|
gpgme_data_t plain,
|
|
gpgme_data_t ciph,
|
|
int use_armor,
|
|
gpgme_ctx_t ctx /* FIXME */);
|
|
gpgme_error_t _gpgme_engine_op_export (engine_t engine, const char *pattern,
|
|
unsigned int reserved,
|
|
gpgme_data_t keydata, int use_armor);
|
|
gpgme_error_t _gpgme_engine_op_export_ext (engine_t engine,
|
|
const char *pattern[],
|
|
unsigned int reserved,
|
|
gpgme_data_t keydata,
|
|
int use_armor);
|
|
gpgme_error_t _gpgme_engine_op_genkey (engine_t engine,
|
|
gpgme_data_t help_data,
|
|
int use_armor, gpgme_data_t pubkey,
|
|
gpgme_data_t seckey);
|
|
gpgme_error_t _gpgme_engine_op_import (engine_t engine,
|
|
gpgme_data_t keydata);
|
|
gpgme_error_t _gpgme_engine_op_keylist (engine_t engine,
|
|
const char *pattern,
|
|
int secret_only,
|
|
gpgme_keylist_mode_t mode);
|
|
gpgme_error_t _gpgme_engine_op_keylist_ext (engine_t engine,
|
|
const char *pattern[],
|
|
int secret_only,
|
|
int reserved,
|
|
gpgme_keylist_mode_t mode);
|
|
gpgme_error_t _gpgme_engine_op_sign (engine_t engine, gpgme_data_t in,
|
|
gpgme_data_t out, gpgme_sig_mode_t mode,
|
|
int use_armor, int use_textmode,
|
|
int include_certs,
|
|
gpgme_ctx_t ctx /* FIXME */);
|
|
gpgme_error_t _gpgme_engine_op_trustlist (engine_t engine,
|
|
const char *pattern);
|
|
gpgme_error_t _gpgme_engine_op_verify (engine_t engine, gpgme_data_t sig,
|
|
gpgme_data_t signed_text,
|
|
gpgme_data_t plaintext);
|
|
|
|
void _gpgme_engine_set_io_cbs (engine_t engine,
|
|
gpgme_io_cbs_t io_cbs);
|
|
void _gpgme_engine_io_event (engine_t engine,
|
|
gpgme_event_io_t type, void *type_data);
|
|
|
|
gpgme_error_t _gpgme_engine_cancel (engine_t engine);
|
|
|
|
#endif /* ENGINE_H */
|