chiark / gitweb /
Import gnupg2_2.1.18-8~deb9u1.debian.tar.bz2
[gnupg2.git] / patches / 0041-gpg-tools-Make-trust-model-configurable-via-gpgconf.patch
1 From: Justus Winter <justus@g10code.com>
2 Date: Tue, 28 Feb 2017 13:15:42 +0100
3 Subject: gpg,tools: Make trust-model configurable via gpgconf.
4
5 * g10/gpg.c (gpgconf_list): Add 'trust-model'.
6 * tools/gpgconf-comp.c (gc_options_gpg): Likewise.
7
8 GnuPG-bug-id: 2381
9 Signed-off-by: Justus Winter <justus@g10code.com>
10 (cherry picked from commit ebeccd73eb85f9027f0985d77dfe901266c6ddef)
11 ---
12  g10/gpg.c            | 1 +
13  tools/gpgconf-comp.c | 4 ++++
14  2 files changed, 5 insertions(+)
15
16 diff --git a/g10/gpg.c b/g10/gpg.c
17 index 0c5a167..09bdf66 100644
18 --- a/g10/gpg.c
19 +++ b/g10/gpg.c
20 @@ -1845,6 +1845,7 @@ gpgconf_list (const char *configfile)
21    es_printf ("group:%lu:\n", GC_OPT_FLAG_NONE);
22    es_printf ("compliance:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT, "gnupg");
23    es_printf ("default-new-key-algo:%lu:\n", GC_OPT_FLAG_NONE);
24 +  es_printf ("trust-model:%lu:\n", GC_OPT_FLAG_NONE);
25  
26    /* The next one is an info only item and should match the macros at
27       the top of keygen.c  */
28 diff --git a/tools/gpgconf-comp.c b/tools/gpgconf-comp.c
29 index a0d9659..cdd2586 100644
30 --- a/tools/gpgconf-comp.c
31 +++ b/tools/gpgconf-comp.c
32 @@ -716,6 +716,10 @@ static gc_option_t gc_options_gpg[] =
33       (GC_OPT_FLAG_ARG_OPT|GC_OPT_FLAG_NO_CHANGE), GC_LEVEL_INVISIBLE,
34       NULL, NULL,
35       GC_ARG_TYPE_STRING, GC_BACKEND_GPG },
36 +   { "trust-model",
37 +     GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE,
38 +     NULL, NULL,
39 +     GC_ARG_TYPE_STRING, GC_BACKEND_GPG },
40  
41  
42     { "Debug",