From: David Kalnischkies <kalnischkies@gmail.com>
Date: Sat, 4 Sep 2010 13:28:47 +0000 (+0200)
Subject: * cmdline/apt-key:
X-Git-Tag: 0.8.2~1^2~2
X-Git-Url: https://git.saurik.com/apt.git/commitdiff_plain/1f8b2599f6beb14e8855f5d43fc1a759a08690e9?ds=sidebyside

* cmdline/apt-key:
  - support also Dir::Etc::Trusted so that apt-key works in the same
    way as the library part which works with the trusted files
---

diff --git a/cmdline/apt-key b/cmdline/apt-key
index 27731ef7d..b39ab12e4 100755
--- a/cmdline/apt-key
+++ b/cmdline/apt-key
@@ -147,11 +147,13 @@ else
 	#echo "generate list"
 	TRUSTEDFILE="/etc/apt/trusted.gpg"
 	eval $(apt-config shell TRUSTEDFILE Apt::GPGV::TrustedKeyring)
+	eval $(apt-config shell TRUSTEDFILE Dir::Etc::Trusted/f)
 	if [ -r "$TRUSTEDFILE" ]; then
 		GPG="$GPG --keyring $TRUSTEDFILE"
 	fi
 	GPG="$GPG --primary-keyring $TRUSTEDFILE"
 	TRUSTEDPARTS="/etc/apt/trusted.gpg.d"
+	eval $(apt-config shell TRUSTEDPARTS Dir::Etc::TrustedParts/d)
 	if [ -d "$TRUSTEDPARTS" ]; then
 		#echo "parts active"
 		for trusted in $(run-parts --list $TRUSTEDPARTS --regex '^.*\.gpg$'); do
diff --git a/debian/changelog b/debian/changelog
index 205777a01..4dca62603 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -10,8 +10,11 @@ apt (0.8.2) UNRELEASED; urgency=low
   * apt-pkg/indexcopy.cc:
     - support really still the APT::GPGV::TrustedKeyring setting,
       as it breaks d-i badly otherwise (Closes: #595428)
+  * cmdline/apt-key:
+    - support also Dir::Etc::Trusted so that apt-key works in the same
+      way as the library part which works with the trusted files
 
- -- David Kalnischkies <kalnischkies@gmail.com>  Sat, 04 Sep 2010 10:45:45 +0200
+ -- David Kalnischkies <kalnischkies@gmail.com>  Sat, 04 Sep 2010 15:25:10 +0200
 
 apt (0.8.1) unstable; urgency=low
 
diff --git a/test/integration/framework b/test/integration/framework
index d832bedbe..8a5973d4b 100644
--- a/test/integration/framework
+++ b/test/integration/framework
@@ -72,6 +72,7 @@ aptconfig() { runapt apt-config $*; }
 aptcache() { runapt apt-cache $*; }
 aptget() { runapt apt-get $*; }
 aptftparchive() { runapt apt-ftparchive $*; }
+aptkey() { runapt apt-key $*; }
 dpkg() {
 	$(which dpkg) --root=${TMPWORKINGDIRECTORY}/rootdir --force-not-root --force-bad-path --log=${TMPWORKINGDIRECTORY}/rootdir/var/log/dpkg.log $*
 }