mirror of
git://git.gnupg.org/gnupg.git
synced 2024-06-06 23:17:47 +02:00
sm: Allow explicit setting of the default --compliance=gnupg
* sm/gpgsm.c (main): Allow setting of the default compliance. * tools/gpgconf-comp.c (gc_options_gpgsm): Add "compliance". -- This is required so that we can use this option in in gpgconf.conf. Signed-off-by: Werner Koch <wk@gnupg.org>
This commit is contained in:
parent
e3ddeff66e
commit
8c878ae4c9
|
@ -31,8 +31,7 @@
|
||||||
#
|
#
|
||||||
# Example file:
|
# Example file:
|
||||||
#==========
|
#==========
|
||||||
# :staff gpg-agent allow-mark-trusted [change]
|
# :staff gpg-agent min-passphrase-len 6 [change]
|
||||||
# gpg-agent min-passphrase-len 6
|
|
||||||
#
|
#
|
||||||
# * gpg-agent min-passphrase-len [no-change] 8
|
# * gpg-agent min-passphrase-len [no-change] 8
|
||||||
# gpg-agent min-passphrase-nonalpha [no-change] 1
|
# gpg-agent min-passphrase-nonalpha [no-change] 1
|
||||||
|
@ -42,9 +41,9 @@
|
||||||
# gpg-agent enforce-passphrase-constraints [no-change]
|
# gpg-agent enforce-passphrase-constraints [no-change]
|
||||||
# gpg-agent max-cache-ttl [no-change] 10800
|
# gpg-agent max-cache-ttl [no-change] 10800
|
||||||
# gpg-agent max-cache-ttl-ssh [no-change] 10800
|
# gpg-agent max-cache-ttl-ssh [no-change] 10800
|
||||||
# gpg-agent allow-mark-trusted [default]
|
|
||||||
# gpg-agent allow-mark-trusted [no-change]
|
|
||||||
# gpgsm enable-ocsp
|
# gpgsm enable-ocsp
|
||||||
|
# gpg compliance [no-change]
|
||||||
|
# gpgsm compliance [no-change]
|
||||||
#===========
|
#===========
|
||||||
# All users in the group "staff" are allowed to change the value for
|
# All users in the group "staff" are allowed to change the value for
|
||||||
# --allow-mark-trusted; gpgconf's default is not to allow a change
|
# --allow-mark-trusted; gpgconf's default is not to allow a change
|
||||||
|
|
|
@ -1450,6 +1450,7 @@ main ( int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct gnupg_compliance_option compliance_options[] =
|
struct gnupg_compliance_option compliance_options[] =
|
||||||
{
|
{
|
||||||
|
{ "gnupg", CO_GNUPG },
|
||||||
{ "de-vs", CO_DE_VS }
|
{ "de-vs", CO_DE_VS }
|
||||||
};
|
};
|
||||||
int compliance = gnupg_parse_compliance_option (pargs.r.ret_str,
|
int compliance = gnupg_parse_compliance_option (pargs.r.ret_str,
|
||||||
|
@ -1786,6 +1787,7 @@ main ( int argc, char **argv)
|
||||||
proc_parameters actually implements. */
|
proc_parameters actually implements. */
|
||||||
es_printf ("default_pubkey_algo:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT,
|
es_printf ("default_pubkey_algo:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT,
|
||||||
"RSA-2048");
|
"RSA-2048");
|
||||||
|
es_printf ("compliance:%lu:\"%s:\n", GC_OPT_FLAG_DEFAULT, "gnupg");
|
||||||
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -833,6 +833,9 @@ static gc_option_t gc_options_gpgsm[] =
|
||||||
(GC_OPT_FLAG_ARG_OPT|GC_OPT_FLAG_NO_CHANGE), GC_LEVEL_INVISIBLE,
|
(GC_OPT_FLAG_ARG_OPT|GC_OPT_FLAG_NO_CHANGE), GC_LEVEL_INVISIBLE,
|
||||||
NULL, NULL,
|
NULL, NULL,
|
||||||
GC_ARG_TYPE_STRING, GC_BACKEND_GPGSM },
|
GC_ARG_TYPE_STRING, GC_BACKEND_GPGSM },
|
||||||
|
{ "compliance", GC_OPT_FLAG_NONE, GC_LEVEL_INVISIBLE,
|
||||||
|
NULL, NULL,
|
||||||
|
GC_ARG_TYPE_STRING, GC_BACKEND_GPGSM },
|
||||||
|
|
||||||
{ "Debug",
|
{ "Debug",
|
||||||
GC_OPT_FLAG_GROUP, GC_LEVEL_ADVANCED,
|
GC_OPT_FLAG_GROUP, GC_LEVEL_ADVANCED,
|
||||||
|
|
Loading…
Reference in New Issue
Block a user