diff options
Diffstat (limited to '')
-rw-r--r-- | sm/ChangeLog | 7 | ||||
-rw-r--r-- | sm/gpgsm.c | 6 | ||||
-rw-r--r-- | sm/server.c | 7 |
3 files changed, 13 insertions, 7 deletions
diff --git a/sm/ChangeLog b/sm/ChangeLog index 6936128de..150d680a3 100644 --- a/sm/ChangeLog +++ b/sm/ChangeLog @@ -1,3 +1,10 @@ +2009-05-18 Werner Koch <[email protected]> + + * server.c (option_handler): New option "no-encrypt-to". + (cmd_encrypt): Make use of it. + + * gpgsm.c: Remove not implemented --verify-files. + 2009-04-02 Werner Koch <[email protected]> * keylist.c (list_cert_std): Print card serial number. diff --git a/sm/gpgsm.c b/sm/gpgsm.c index 8a2a1c0b9..cb9aaab44 100644 --- a/sm/gpgsm.c +++ b/sm/gpgsm.c @@ -66,7 +66,6 @@ enum cmd_and_opt_values { aDeleteKey, aImport, aVerify, - aVerifyFiles, aListExternalKeys, aListChain, aSendKeys, @@ -191,7 +190,6 @@ static ARGPARSE_OPTS opts[] = { ARGPARSE_c (aSym, "symmetric", N_("encryption only with symmetric cipher")), ARGPARSE_c (aDecrypt, "decrypt", N_("decrypt data (default)")), ARGPARSE_c (aVerify, "verify", N_("verify a signature")), - ARGPARSE_c (aVerifyFiles, "verify-files", "@"), ARGPARSE_c (aListKeys, "list-keys", N_("list keys")), ARGPARSE_c (aListExternalKeys, "list-external-keys", N_("list external keys")), @@ -1711,10 +1709,6 @@ main ( int argc, char **argv) } break; - case aVerifyFiles: - log_error (_("this command has not yet been implemented\n")); - break; - case aDecrypt: { FILE *fp = open_fwrite (opt.outfile?opt.outfile:"-"); diff --git a/sm/server.c b/sm/server.c index 6b9eeb82d..dfd4f690f 100644 --- a/sm/server.c +++ b/sm/server.c @@ -51,6 +51,7 @@ struct server_local_s { certlist_t default_recplist; /* As set by main() - don't release. */ int allow_pinentry_notify; /* Set if pinentry notifications should be passed back to the client. */ + int no_encrypt_to; /* Local version of option. */ }; @@ -301,6 +302,10 @@ option_handler (assuan_context_t ctx, const char *key, const char *value) int i = *value? atoi (value) : 0; ctrl->with_ephemeral_keys = i; } + else if (!strcmp (key, "no-encrypt-to")) + { + ctrl->server_local->no_encrypt_to = 1; + } else return gpg_error (GPG_ERR_UNKNOWN_OPTION); @@ -486,7 +491,7 @@ cmd_encrypt (assuan_context_t ctx, char *line) /* Now add all encrypt-to marked recipients from the default list. */ rc = 0; - if (!opt.no_encrypt_to) + if (!opt.no_encrypt_to && !ctrl->server_local->no_encrypt_to) { for (cl=ctrl->server_local->default_recplist; !rc && cl; cl = cl->next) if (cl->is_encrypt_to) |