summaryrefslogtreecommitdiff
path: root/src/engine.h
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2016-09-14 20:21:19 +0200
committerWerner Koch <wk@gnupg.org>2016-09-14 20:21:19 +0200
commit7c37719d79345a665ec2f4570e3f257033b58c62 (patch)
tree10cccebe681f29cbf6b83e27f2a7f805b6b6abe8 /src/engine.h
parentd79dcb78d867aaf55b85aea117c4ae6035a1531a (diff)
downloadgpgme-7c37719d79345a665ec2f4570e3f257033b58c62.tar.gz
core: New function gpgme_op_tofu_policy
* src/gpgme.h.in (gpgme_op_tofu_policy_start): New function. (gpgme_op_tofu_policy): New function. * src/libgpgme.vers, src/gpgme.def: Add new functions. * src/tofupolicy.c: New. * src/Makefile.am (main_sources): Add that file. * src/context.h (ctx_op_data_id_t): Add OPDATA_TOFU_POLICY. * src/engine.c (_gpgme_engine_op_tofu_policy): New. * src/engine-backend.h (engine_ops): Add funcptr 'tofu_policy'. Adjust all engine initializations. * src/engine-gpg.c (gpg_tofu_policy): New. (_gpgme_engine_ops_gpg): Register this function. * tests/run-tofu.c: New. * tests/Makefile.am (noinst_PROGRAMS): Add it. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'src/engine.h')
-rw-r--r--src/engine.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/engine.h b/src/engine.h
index 6f338351..4ce2bed1 100644
--- a/src/engine.h
+++ b/src/engine.h
@@ -126,6 +126,9 @@ gpgme_error_t _gpgme_engine_op_keysign (engine_t engine,
unsigned long expires,
unsigned int flags,
gpgme_ctx_t ctx);
+gpgme_error_t _gpgme_engine_op_tofu_policy (engine_t engine,
+ gpgme_key_t key,
+ gpgme_tofu_policy_t policy);
gpgme_error_t _gpgme_engine_op_import (engine_t engine,
gpgme_data_t keydata,
gpgme_key_t *keyarray);