aboutsummaryrefslogtreecommitdiffstats
path: root/g10/gpg.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2018-05-29 10:42:44 +0000
committerWerner Koch <[email protected]>2018-05-29 10:42:52 +0000
commit253e8bdd9014cbe6dc06adce9d9dd2f8f4b31709 (patch)
treece2d7b23b0025145cfdf722d27a7501b81f9b0b7 /g10/gpg.c
parentgpg: Fix detection of the AEAD feature flag. (diff)
downloadgnupg-253e8bdd9014cbe6dc06adce9d9dd2f8f4b31709.tar.gz
gnupg-253e8bdd9014cbe6dc06adce9d9dd2f8f4b31709.zip
gpg: Remove MDC options
* g10/gpg.c: Tuen options --force-mdc, --no-force-mdc, --disable-mdc and --no-disable-mdc into NOPs. * g10/encrypt.c (use_mdc): Simplify. MDC is now almost always used. (use_aead): Ignore MDC options. Print warning for missing MDC feature flags. * g10/pkclist.c (warn_missing_mdc_from_pklist): Rename to ... (warn_missing_aead_from_pklist): this and adjust. -- The MDC is now always used except with --rfc2440 which will lead to a a big fat warning. Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'g10/gpg.c')
-rw-r--r--g10/gpg.c21
1 files changed, 5 insertions, 16 deletions
diff --git a/g10/gpg.c b/g10/gpg.c
index e718fe45e..1a419f7e7 100644
--- a/g10/gpg.c
+++ b/g10/gpg.c
@@ -301,10 +301,6 @@ enum cmd_and_opt_values
oShowPhotos,
oNoShowPhotos,
oPhotoViewer,
- oForceMDC,
- oNoForceMDC,
- oDisableMDC,
- oNoDisableMDC,
oForceAEAD,
oS2KMode,
oS2KDigest,
@@ -605,11 +601,6 @@ static ARGPARSE_OPTS opts[] = {
ARGPARSE_s_n (oQuiet, "quiet", "@"),
ARGPARSE_s_n (oNoTTY, "no-tty", "@"),
- ARGPARSE_s_n (oForceMDC, "force-mdc", "@"),
- ARGPARSE_s_n (oNoForceMDC, "no-force-mdc", "@"),
- ARGPARSE_s_n (oDisableMDC, "disable-mdc", "@"),
- ARGPARSE_s_n (oNoDisableMDC, "no-disable-mdc", "@"),
-
ARGPARSE_s_n (oForceAEAD, "force-aead", "@"),
ARGPARSE_s_n (oDisableSignerUID, "disable-signer-uid", "@"),
@@ -924,6 +915,11 @@ static ARGPARSE_OPTS opts[] = {
ARGPARSE_s_n (oNoop, "force-v4-certs", "@"),
ARGPARSE_s_n (oNoop, "no-force-v4-certs", "@"),
ARGPARSE_s_n (oNoop, "no-mdc-warning", "@"),
+ ARGPARSE_s_n (oNoop, "force-mdc", "@"),
+ ARGPARSE_s_n (oNoop, "no-force-mdc", "@"),
+ ARGPARSE_s_n (oNoop, "disable-mdc", "@"),
+ ARGPARSE_s_n (oNoop, "no-disable-mdc", "@"),
+
ARGPARSE_end ()
};
@@ -2201,7 +2197,6 @@ set_compliance_option (enum cmd_and_opt_values option)
case oDE_VS:
set_compliance_option (oOpenPGP);
opt.compliance = CO_DE_VS;
- opt.force_mdc = 1;
opt.def_aead_algo = 0;
/* Fixme: Change other options. */
break;
@@ -3019,11 +3014,6 @@ main (int argc, char **argv)
break;
case oPhotoViewer: opt.photo_viewer = pargs.r.ret_str; break;
- case oForceMDC: opt.force_mdc = 1; break;
- case oNoForceMDC: opt.force_mdc = 0; break;
- case oDisableMDC: opt.disable_mdc = 1; break;
- case oNoDisableMDC: opt.disable_mdc = 0; break;
-
case oForceAEAD: opt.force_aead = 1; break;
case oDisableSignerUID: opt.flags.disable_signer_uid = 1; break;
@@ -3802,7 +3792,6 @@ main (int argc, char **argv)
{
/* That does not anymore work because we have no more support
for v3 signatures. */
- opt.disable_mdc=1;
opt.escape_from=1;
opt.ask_sig_expire=0;
}