From 4368851d55589a55fc10ff347890d8bbf33ee002 Mon Sep 17 00:00:00 2001 From: David Kalnischkies Date: Thu, 19 Aug 2010 00:04:05 +0200 Subject: * apt-pkg/init.cc: - set the default values for dir::etc::trusted options correctly --- apt-pkg/indexcopy.cc | 5 ++--- apt-pkg/init.cc | 3 +++ debian/changelog | 4 +++- methods/gpgv.cc | 2 +- 4 files changed, 9 insertions(+), 5 deletions(-) diff --git a/apt-pkg/indexcopy.cc b/apt-pkg/indexcopy.cc index b4e587d7b..a2a1d5934 100644 --- a/apt-pkg/indexcopy.cc +++ b/apt-pkg/indexcopy.cc @@ -661,9 +661,8 @@ bool SigVerify::RunGPGV(std::string const &File, std::string const &FileGPG, { string const gpgvpath = _config->Find("Dir::Bin::gpg", "/usr/bin/gpgv"); // FIXME: remove support for deprecated APT::GPGV setting - string const trustedFile = _config->FindFile("Dir::Etc::Trusted", - _config->Find("APT::GPGV::TrustedKeyring", "/etc/apt/trusted.gpg").c_str()); - string const trustedPath = _config->FindDir("Dir::Etc::TrustedParts", "/etc/apt/trusted.gpg.d"); + string const trustedFile = _config->FindFile("Dir::Etc::Trusted"); + string const trustedPath = _config->FindDir("Dir::Etc::TrustedParts"); bool const Debug = _config->FindB("Debug::Acquire::gpgv", false); diff --git a/apt-pkg/init.cc b/apt-pkg/init.cc index 7a332c86e..846b27313 100644 --- a/apt-pkg/init.cc +++ b/apt-pkg/init.cc @@ -70,6 +70,9 @@ bool pkgInitConfig(Configuration &Cnf) Cnf.Set("Dir::Etc::parts","apt.conf.d"); Cnf.Set("Dir::Etc::preferences","preferences"); Cnf.Set("Dir::Etc::preferencesparts","preferences.d"); + string const deprecated = _config->Find("APT::GPGV::TrustedKeyring"); + Cnf.Set("Dir::Etc::trusted", deprecated.empty() ? "trusted.gpg" : deprecated); + Cnf.Set("Dir::Etc::trustedparts","trusted.gpg.d"); Cnf.Set("Dir::Bin::methods","/usr/lib/apt/methods"); Cnf.Set("Dir::Media::MountPath","/media/apt"); diff --git a/debian/changelog b/debian/changelog index 4fdfb2769..91300e10c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -7,8 +7,10 @@ apt (0.8.0~pre2) UNRELEASED; urgency=low - fix error checking for read in case of failing bzip2/lzma/whatever * debian/apt.cron.daily: - create backups for our extended_states file (Closes: #593430) + * apt-pkg/init.cc: + - set the default values for dir::etc::trusted options correctly - -- David Kalnischkies Wed, 18 Aug 2010 11:09:52 +0200 + -- David Kalnischkies Thu, 19 Aug 2010 00:01:30 +0200 apt (0.8.0~pre1) experimental; urgency=low diff --git a/methods/gpgv.cc b/methods/gpgv.cc index 018e4f622..efe1f73f7 100644 --- a/methods/gpgv.cc +++ b/methods/gpgv.cc @@ -69,7 +69,7 @@ string GPGVMethod::VerifyGetSigners(const char *file, const char *outfile, { // TRANSLATOR: %s is the trusted keyring parts directory ioprintf(ret, _("No keyring installed in %s."), - _config->FindDir("Dir::Etc::TrustedParts", "/etc/apt/trusted.gpg.d").c_str()); + _config->FindDir("Dir::Etc::TrustedParts").c_str()); return ret.str(); } exit(111); -- cgit v1.2.3