From 933adc0850a6efd2fc7bb805c0471a80f1ef970c Mon Sep 17 00:00:00 2001 From: David Shaw Date: Fri, 29 Oct 2010 19:16:27 +0000 Subject: * gpg.c (main): Do not provide a default for --personal-digest-preferences. This allows the usual digest selection algorithm to pick a digest based on recipient keys. --- g10/ChangeLog | 4 ++++ g10/gpg.c | 7 +------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/g10/ChangeLog b/g10/ChangeLog index 5d0d69c46..86d6e3e50 100644 --- a/g10/ChangeLog +++ b/g10/ChangeLog @@ -1,5 +1,9 @@ 2010-10-29 David Shaw + * gpg.c (main): Do not provide a default for + --personal-digest-preferences. This allows the usual digest + selection algorithm to pick a digest based on recipient keys. + * pkclist.c (select_algo_from_prefs): Make sure the scores can't overflow when picking an algorithm (not a security issue since we can't pick something not present in all preference lists, but we diff --git a/g10/gpg.c b/g10/gpg.c index 0142168e0..cf2f51b68 100644 --- a/g10/gpg.c +++ b/g10/gpg.c @@ -1,6 +1,6 @@ /* gpg.c - The GnuPG utility (main for gpg) * Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - * 2007, 2008, 2009 Free Software Foundation, Inc. + * 2007, 2008, 2009, 2010 Free Software Foundation, Inc. * * This file is part of GnuPG. * @@ -3148,11 +3148,6 @@ main (int argc, char **argv ) keygen_set_std_prefs(opt.def_preference_list,0)) log_error(_("invalid default preferences\n")); - /* We provide defaults for the personal digest list. This is - SHA-1. */ - if(!pers_digest_list) - pers_digest_list="h2"; - if(pers_cipher_list && keygen_set_std_prefs(pers_cipher_list,PREFTYPE_SYM)) log_error(_("invalid personal cipher preferences\n")); -- cgit v1.2.3